@@ -29,7 +29,7 @@ using namespace AV1EHW;
2929using namespace AV1EHW ::Base;
3030using namespace AV1EHW ::Linux::Base;
3131
32- mfxStatus DDI_VA::SetDDIID (const mfxU16 bitDepth, const mfxU16 chromFormat, const mfxU32 /* fourCC */ , const mfxU16 /* targetChromaFormat */ )
32+ mfxStatus DDI_VA::SetDDIID (const mfxU16 bitDepth, const mfxU16 chromFormat)
3333{
3434 MFX_CHECK (!m_vaid, MFX_ERR_NONE);
3535
@@ -114,19 +114,17 @@ void DDI_VA::Query1NoCaps(const FeatureBlocks& /*blocks*/, TPushQ1 Push)
114114
115115 m_hw = Glob::VideoCore::Get (strg).GetHWType ();
116116 const mfxU16 bitDepth = m_pDefaults->base .GetBitDepthLuma (*m_pDefaults);
117- const mfxU16 chromaFormat = par.mfx .FrameInfo .ChromaFormat ;
118- const mfxU32 fourCC = par.mfx .FrameInfo .FourCC ;
119117 const mfxU16 profile = par.mfx .CodecProfile ;
120118 const mfxExtCodingOption3* pCO3 = ExtBuffer::Get (m_pDefaults->mvp );
121- mfxU16 targetChromaFormat = MFX_CHROMAFORMAT_YUV420 ;
119+ mfxU16 targetChromaFormat = m_pDefaults-> base . GetTargetChromaFormatPlus1 (*m_pDefaults) - 1 ; ;
122120
123121 SetIf (targetChromaFormat, profile == MFX_PROFILE_AV1_HIGH, MFX_CHROMAFORMAT_YUV444);
124122 if (pCO3)
125123 {
126124 SetIf (targetChromaFormat, !pCO3->TargetChromaFormatPlus1 , pCO3->TargetChromaFormatPlus1 - 1 );
127125 }
128126
129- MFX_SAFE_CALL (SetDDIID (bitDepth, chromaFormat, fourCC, targetChromaFormat));
127+ MFX_SAFE_CALL (SetDDIID (bitDepth, targetChromaFormat));
130128
131129 return MFX_ERR_NONE;
132130 });
@@ -398,6 +396,7 @@ mfxStatus DDI_VA::QueryCaps()
398396 MFX_CHECK_STS (sts);
399397
400398 m_caps.ChromaSupportFlags .fields .i420 = !!(AV (VAConfigAttribRTFormat) & VA_RT_FORMAT_YUV420);
399+ m_caps.ChromaSupportFlags .fields .RGB = !!(AV (VAConfigAttribRTFormat) & VA_RT_FORMAT_RGB32);
401400
402401 m_caps.BitDepthSupportFlags .fields .eight_bits = !!(AV (VAConfigAttribRTFormat) & VA_RT_FORMAT_YUV420);
403402 m_caps.BitDepthSupportFlags .fields .ten_bits = !!(AV (VAConfigAttribRTFormat) & VA_RT_FORMAT_YUV420_10BPP);
0 commit comments