Merge pull request #10252 from heitbaum/media12.2

[le12.2] update media packages
This commit is contained in:
Matthias Reichl 2025-07-22 17:15:23 +02:00 committed by GitHub
commit 8ec49f99bc
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
6 changed files with 27 additions and 174 deletions

View File

@ -2,8 +2,8 @@
# Copyright (C) 2016-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="libva-utils"
PKG_VERSION="2.20.1"
PKG_SHA256="97413a7ec27ec479b97ffc7ab8acebe053615224a4b051602859cf9f88e4e889"
PKG_VERSION="2.22.0"
PKG_SHA256="7b57615c130427ec134bb5d2b80af516ce5bb19a40e89b1dab46a0d59760d96c"
PKG_LICENSE="GPL"
PKG_SITE="https://github.com/01org/libva-utils"
PKG_URL="https://github.com/intel/libva-utils/archive/${PKG_VERSION}.tar.gz"

View File

@ -3,17 +3,18 @@
# Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="libdrm"
PKG_VERSION="2.4.120"
PKG_SHA256="3bf55363f76c7250946441ab51d3a6cc0ae518055c0ff017324ab76cdefb327a"
PKG_VERSION="2.4.125"
PKG_SHA256="d4bae92797a50f81a93524762e0410a49cd84cfa0f997795bc0172ac8fb1d96a"
PKG_LICENSE="GPL"
PKG_SITE="https://dri.freedesktop.org"
PKG_URL="https://dri.freedesktop.org/libdrm/libdrm-${PKG_VERSION}.tar.xz"
PKG_DEPENDS_HOST="toolchain:host"
PKG_DEPENDS_TARGET="toolchain libpciaccess"
PKG_LONGDESC="The userspace interface library to kernel DRM services."
get_graphicdrivers
PKG_MESON_OPTS_TARGET="-Dnouveau=disabled \
PKG_MESON_OPTS_COMMON="-Dnouveau=disabled \
-Domap=disabled \
-Dexynos=disabled \
-Dtegra=disabled \
@ -21,9 +22,23 @@ PKG_MESON_OPTS_TARGET="-Dnouveau=disabled \
-Dman-pages=disabled \
-Dvalgrind=disabled \
-Dfreedreno-kgsl=false \
-Dinstall-test-programs=true \
-Dudev=false"
PKG_MESON_OPTS_HOST="${PKG_MESON_OPTS_COMMON} \
-Damdgpu=disabled \
-Detnaviv=disabled \
-Dfreedreno=disabled \
-Dintel=disabled \
-Dradeon=disabled \
-Dvc4=disabled \
-Dvmwgfx=disabled \
-Dtests=false \
-Dinstall-test-programs=false"
PKG_MESON_OPTS_TARGET="${PKG_MESON_OPTS_COMMON} \
-Dtests=true \
-Dinstall-test-programs=true"
listcontains "${GRAPHIC_DRIVERS}" "(crocus|i915|iris)" &&
PKG_MESON_OPTS_TARGET+=" -Dintel=enabled" || PKG_MESON_OPTS_TARGET+=" -Dintel=disabled"

View File

@ -2,8 +2,8 @@
# Copyright (C) 2019-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="gmmlib"
PKG_VERSION="22.3.18"
PKG_SHA256="381f7ad104e3d0d8dd6c3ec0c8304e410a479c439e72db35c83fb7e2b0ec556f"
PKG_VERSION="22.8.1"
PKG_SHA256="9b8eac1891650021ded26b72585e7a2c702a3ba47565c968feabd14ab38d18f7"
PKG_ARCH="x86_64"
PKG_LICENSE="MIT"
PKG_SITE="https://01.org/linuxmedia"

View File

@ -3,8 +3,8 @@
# Copyright (C) 2018-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="libva"
PKG_VERSION="2.20.0"
PKG_SHA256="117f8d658a5fc9ea406ca80a3eb4ae1d70b15a54807c9ed77199c812bed73b60"
PKG_VERSION="2.22.0"
PKG_SHA256="467c418c2640a178c6baad5be2e00d569842123763b80507721ab87eb7af8735"
PKG_ARCH="x86_64"
PKG_LICENSE="GPL"
PKG_SITE="https://01.org/linuxmedia"

View File

@ -2,8 +2,8 @@
# Copyright (C) 2019-present Team LibreELEC (https://libreelec.tv)
PKG_NAME="media-driver"
PKG_VERSION="24.1.5"
PKG_SHA256="e23ea37c98d8d4b9d1a3a134b6489256d8f5a7a4ee71967b1db8ade70052654f"
PKG_VERSION="25.2.6"
PKG_SHA256="ba0f124c8e08e0675725f9631b7b1b1c371944b31b7a58a62d2c99338e7ce230"
PKG_ARCH="x86_64"
PKG_LICENSE="MIT"
PKG_SITE="https://01.org/linuxmedia"

View File

@ -1,162 +0,0 @@
From 1e79d58e7af77453e55ce40fe01c1cc8ca84461b Mon Sep 17 00:00:00 2001
From: Jason Chen <jason.k.chen@intel.com>
Date: Thu, 18 Mar 2021 11:52:11 +0800
Subject: [PATCH] [VP] Use forward_references as the reference for ADI
VAAPI define forward_references as past referene frame, but vphal regart forward reference as future reference frame. This change will only correct the behavior in DDI level to map forward_references to VPHAL_SURFACE.pBwdRef, and backward_references to VPHAL_SURFACE.pFwdRef
---
media_driver/linux/common/ddi/media_libva.cpp | 17 ++++++++
.../linux/common/vp/ddi/media_libva_vp.c | 42 ++++++++++---------
2 files changed, 39 insertions(+), 20 deletions(-)
diff --git a/media_driver/linux/common/ddi/media_libva.cpp b/media_driver/linux/common/ddi/media_libva.cpp
index 63f1659ed..efa0c08cc 100755
--- a/media_driver/linux/common/ddi/media_libva.cpp
+++ b/media_driver/linux/common/ddi/media_libva.cpp
@@ -6525,6 +6525,23 @@ DdiMedia_QueryVideoProcPipelineCaps(
pipeline_caps->min_output_width = VP_MIN_PIC_WIDTH;
pipeline_caps->min_output_height = VP_MIN_PIC_WIDTH;
}
+
+ for (int i = 0; i < num_filters; i++) {
+ void *pData;
+ DdiMedia_MapBuffer(ctx, filters[i], &pData);
+ DDI_CHK_NULL(pData, "nullptr pData", VA_STATUS_ERROR_INVALID_PARAMETER);
+ VAProcFilterParameterBufferBase* base_param = (VAProcFilterParameterBufferBase*) pData;
+ if (base_param->type == VAProcFilterDeinterlacing)
+ {
+ VAProcFilterParameterBufferDeinterlacing *di_param = (VAProcFilterParameterBufferDeinterlacing *)base_param;
+ if (di_param->algorithm == VAProcDeinterlacingMotionAdaptive ||
+ di_param->algorithm == VAProcDeinterlacingMotionCompensated)
+ {
+ pipeline_caps->num_forward_references = 1;
+ }
+ }
+ }
+
return VA_STATUS_SUCCESS;
}
diff --git a/media_driver/linux/common/vp/ddi/media_libva_vp.c b/media_driver/linux/common/vp/ddi/media_libva_vp.c
index 1f544749b..7d5b95b4e 100644
--- a/media_driver/linux/common/vp/ddi/media_libva_vp.c
+++ b/media_driver/linux/common/vp/ddi/media_libva_vp.c
@@ -90,8 +90,8 @@ VAStatus DdiVp_SetProcFilterTotalColorCorrectionParams(PDDI_VP_CONTEXT, uint
VAStatus DdiVp_SetProcFilterHdrTmParams(PDDI_VP_CONTEXT, uint32_t, VAProcFilterParameterBufferHDRToneMapping*);
VAStatus DdiVp_SetProcPipelineBlendingParams(PDDI_VP_CONTEXT pVpCtx, uint32_t uiSurfIndex, VAProcPipelineParameterBuffer* pPipelineParam);
VAStatus DdiVp_ConvertSurface (VADriverContextP ctx, DDI_MEDIA_SURFACE *srcSurface, int16_t srcx, int16_t srcy, uint16_t srcw, uint16_t srch, DDI_MEDIA_SURFACE *dstSurface, int16_t destx, int16_t desty, uint16_t destw, uint16_t desth );
-VAStatus DdiVp_UpdateProcPipelineForwardReferenceFrames(PDDI_VP_CONTEXT pVpCtx, VADriverContextP pVaDrvCtx, PVPHAL_SURFACE pVpHalSrcSurf, VAProcPipelineParameterBuffer* pPipelineParam);
-VAStatus DdiVp_UpdateProcPipelineBackwardReferenceFrames(PDDI_VP_CONTEXT pVpCtx, VADriverContextP pVaDrvCtx, PVPHAL_SURFACE pVpHalSrcSurf, VAProcPipelineParameterBuffer* pPipelineParam);
+VAStatus DdiVp_UpdateProcPipelineFutureReferenceFrames(PDDI_VP_CONTEXT pVpCtx, VADriverContextP pVaDrvCtx, PVPHAL_SURFACE pVpHalSrcSurf, VAProcPipelineParameterBuffer* pPipelineParam);
+VAStatus DdiVp_UpdateProcPipelinePastReferenceFrames(PDDI_VP_CONTEXT pVpCtx, VADriverContextP pVaDrvCtx, PVPHAL_SURFACE pVpHalSrcSurf, VAProcPipelineParameterBuffer* pPipelineParam);
VAStatus DdiVp_UpdateVphalTargetSurfColorSpace(VADriverContextP, PDDI_VP_CONTEXT, VAProcPipelineParameterBuffer*, uint32_t targetIndex);
VAStatus DdiVp_BeginPictureInt(VADriverContextP pVaDrvCtx, PDDI_VP_CONTEXT pVpCtx, VASurfaceID vaSurfID);
@@ -1174,15 +1174,15 @@ DdiVp_SetProcPipelineParams(
// Update fwd and bkward ref frames: Required for Advanced processing - will be supported in the future
- pVpHalSrcSurf->uFwdRefCount = pPipelineParam->num_forward_references;
+ pVpHalSrcSurf->uFwdRefCount = pPipelineParam->num_backward_references;
- vaStatus = DdiVp_UpdateProcPipelineForwardReferenceFrames(pVpCtx, pVaDrvCtx, pVpHalSrcSurf, pPipelineParam);
- DDI_CHK_RET(vaStatus, "Failed to update forward reference frames!");
+ vaStatus = DdiVp_UpdateProcPipelineFutureReferenceFrames(pVpCtx, pVaDrvCtx, pVpHalSrcSurf, pPipelineParam);
+ DDI_CHK_RET(vaStatus, "Failed to update future reference frames!");
- pVpHalSrcSurf->uBwdRefCount = pPipelineParam->num_backward_references;
+ pVpHalSrcSurf->uBwdRefCount = pPipelineParam->num_forward_references;
- vaStatus = DdiVp_UpdateProcPipelineBackwardReferenceFrames(pVpCtx, pVaDrvCtx, pVpHalSrcSurf, pPipelineParam);
- DDI_CHK_RET(vaStatus, "Failed to update backward reference frames!");
+ vaStatus = DdiVp_UpdateProcPipelinePastReferenceFrames(pVpCtx, pVaDrvCtx, pVpHalSrcSurf, pPipelineParam);
+ DDI_CHK_RET(vaStatus, "Failed to update past reference frames!");
// Check if filter values changed,if yes, then reset all filters for this surface
@@ -3890,7 +3890,7 @@ DdiVp_SetProcPipelineBlendingParams(
}
////////////////////////////////////////////////////////////////////////////////
-//! \purpose Update the forward reference frames for VPHAL input surface
+//! \purpose Update the future reference frames for VPHAL input surface
//! \params
//! [in] pVpCtx : VP context
//! [in] pVaDrvCtx : VA Driver context
@@ -3900,7 +3900,7 @@ DdiVp_SetProcPipelineBlendingParams(
//! \returns VA_STATUS_SUCCESS if call succeeds
////////////////////////////////////////////////////////////////////////////////
VAStatus
-DdiVp_UpdateProcPipelineForwardReferenceFrames(
+DdiVp_UpdateProcPipelineFutureReferenceFrames(
PDDI_VP_CONTEXT pVpCtx,
VADriverContextP pVaDrvCtx,
PVPHAL_SURFACE pVpHalSrcSurf,
@@ -3930,9 +3930,10 @@ DdiVp_UpdateProcPipelineForwardReferenceFrames(
pSurface = pVpHalSrcSurf;
- if (pPipelineParam->forward_references != nullptr)
+ // DDI regard backward_references as future frame, but VPHAL regard pFwdRef as future frame
+ if (pPipelineParam->backward_references != nullptr)
{
- for (i = 0;i < pPipelineParam->num_forward_references; i++)
+ for (i = 0;i < pPipelineParam->num_backward_references; i++)
{
PDDI_MEDIA_SURFACE pRefSurfBuffObj = nullptr;
if(pSurface->pFwdRef == nullptr)
@@ -3952,9 +3953,9 @@ DdiVp_UpdateProcPipelineForwardReferenceFrames(
pSurface->pFwdRef->dwWidth = pVpHalSrcSurf->dwWidth;
pSurface->pFwdRef->dwHeight = pVpHalSrcSurf->dwHeight;
pSurface->pFwdRef->dwPitch = pVpHalSrcSurf->dwPitch;
- pSurface->uFwdRefCount = pPipelineParam->num_forward_references - i;
+ pSurface->uFwdRefCount = pPipelineParam->num_backward_references - i;
}
- pRefSurfBuffObj = DdiMedia_GetSurfaceFromVASurfaceID(pMediaCtx, pPipelineParam->forward_references[i]);
+ pRefSurfBuffObj = DdiMedia_GetSurfaceFromVASurfaceID(pMediaCtx, pPipelineParam->backward_references[i]);
DDI_CHK_NULL(pRefSurfBuffObj,
"Null pRefSurfBuffObj!",
VA_STATUS_ERROR_INVALID_SURFACE);
@@ -3979,7 +3980,7 @@ DdiVp_UpdateProcPipelineForwardReferenceFrames(
}
////////////////////////////////////////////////////////////////////////////////
-//! \purpose Update the backward reference frames for VPHAL input surface
+//! \purpose Update the past reference frames for VPHAL input surface
//! \params
//! [in] pVpCtx : VP context
//! [in] pVaDrvCtx : VA Driver context
@@ -3989,7 +3990,7 @@ DdiVp_UpdateProcPipelineForwardReferenceFrames(
//! \returns VA_STATUS_SUCCESS if call succeeds
////////////////////////////////////////////////////////////////////////////////
VAStatus
-DdiVp_UpdateProcPipelineBackwardReferenceFrames(
+DdiVp_UpdateProcPipelinePastReferenceFrames(
PDDI_VP_CONTEXT pVpCtx,
VADriverContextP pVaDrvCtx,
PVPHAL_SURFACE pVpHalSrcSurf,
@@ -4019,9 +4020,10 @@ DdiVp_UpdateProcPipelineBackwardReferenceFrames(
pSurface = pVpHalSrcSurf;
- if (pPipelineParam->backward_references != nullptr)
+ // DDI regard forward_references as past frame, but VPHAL regard pBwdRef as past frame
+ if (pPipelineParam->forward_references != nullptr)
{
- for (i = 0;i < pPipelineParam->num_backward_references; i++)
+ for (i = 0;i < pPipelineParam->num_forward_references; i++)
{
PDDI_MEDIA_SURFACE pRefSurfBuffObj = nullptr;
if(pSurface->pBwdRef == nullptr)
@@ -4041,9 +4043,9 @@ DdiVp_UpdateProcPipelineBackwardReferenceFrames(
pSurface->pBwdRef->dwWidth = pVpHalSrcSurf->dwWidth;
pSurface->pBwdRef->dwHeight = pVpHalSrcSurf->dwHeight;
pSurface->pBwdRef->dwPitch = pVpHalSrcSurf->dwPitch;
- pSurface->uBwdRefCount = pPipelineParam->num_backward_references - i;;
+ pSurface->uBwdRefCount = pPipelineParam->num_forward_references - i;;
}
- pRefSurfBuffObj = DdiMedia_GetSurfaceFromVASurfaceID(pMediaCtx, pPipelineParam->backward_references[i]);
+ pRefSurfBuffObj = DdiMedia_GetSurfaceFromVASurfaceID(pMediaCtx, pPipelineParam->forward_references[i]);
DDI_CHK_NULL(pRefSurfBuffObj,
"Null pRefSurfBuffObj!",
VA_STATUS_ERROR_INVALID_SURFACE);