From 88e60b40f7d09a6f37ede9b054f1903303c62499 Mon Sep 17 00:00:00 2001 From: Chen_Ke Date: Mon, 2 Sep 2024 16:43:53 +0800 Subject: [PATCH] [VP] Remove duplicated getInfo: fixing S3D failure Remove duplicated getInfo: fixing S3D failures --- .../vp/hal/packet/vp_render_cmd_packet.cpp | 20 ++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/media_softlet/agnostic/common/vp/hal/packet/vp_render_cmd_packet.cpp b/media_softlet/agnostic/common/vp/hal/packet/vp_render_cmd_packet.cpp index 8f9fbe8157..9962d91c92 100644 --- a/media_softlet/agnostic/common/vp/hal/packet/vp_render_cmd_packet.cpp +++ b/media_softlet/agnostic/common/vp/hal/packet/vp_render_cmd_packet.cpp @@ -1044,7 +1044,25 @@ MOS_STATUS VpRenderCmdPacket::InitRenderHalSurface(VP_SURFACE &surface, RENDERHA { VP_FUNC_CALL(); VP_RENDER_CHK_NULL_RETURN(surface.osSurface); - VP_RENDER_CHK_STATUS_RETURN(RenderCmdPacket::InitRenderHalSurface(*surface.osSurface, &renderSurface)); + PMOS_INTERFACE pOsInterface = nullptr; + RENDER_PACKET_CHK_NULL_RETURN(m_renderHal->pOsInterface); + pOsInterface = m_renderHal->pOsInterface; + RENDER_PACKET_CHK_NULL_RETURN(pOsInterface->pfnGetMemoryCompressionMode); + RENDER_PACKET_CHK_NULL_RETURN(pOsInterface->pfnGetMemoryCompressionFormat); + + // Update compression status + VP_PUBLIC_CHK_STATUS_RETURN(pOsInterface->pfnGetMemoryCompressionMode(pOsInterface, + &surface.osSurface->OsResource, + &surface.osSurface->MmcState)); + + VP_PUBLIC_CHK_STATUS_RETURN(pOsInterface->pfnGetMemoryCompressionFormat(pOsInterface, + &surface.osSurface->OsResource, + &surface.osSurface->CompressionFormat)); + + if (Mos_ResourceIsNull(&renderSurface.OsSurface.OsResource)) + { + renderSurface.OsSurface = *surface.osSurface; + } renderSurface.rcSrc = surface.rcSrc; renderSurface.rcDst = surface.rcDst;