mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
msdk: map MFX_FOURCC_Y216 to VA_FOURCC_Y216
In media driver, Y216 is used for packed 12 bits 4:2:2 format YUV format, so the RT format is VA_RT_FORMAT_YUV422_12.
This commit is contained in:
parent
fb200ccfdd
commit
34177985e2
2 changed files with 5 additions and 0 deletions
|
@ -142,6 +142,9 @@ gst_msdk_frame_alloc (mfxHDL pthis, mfxFrameAllocRequest * req,
|
|||
#if ((MFX_VERSION >= 1031) && VA_CHECK_VERSION(1, 2, 0))
|
||||
if (format == VA_RT_FORMAT_YUV420 && va_fourcc == VA_FOURCC_P016)
|
||||
format = VA_RT_FORMAT_YUV420_12;
|
||||
|
||||
if (format == VA_RT_FORMAT_YUV422 && va_fourcc == VA_FOURCC_Y216)
|
||||
format = VA_RT_FORMAT_YUV422_12;
|
||||
#endif
|
||||
|
||||
va_status = vaCreateSurfaces (gst_msdk_context_get_handle (context),
|
||||
|
@ -396,6 +399,7 @@ gst_msdk_frame_lock (mfxHDL pthis, mfxMemId mid, mfxFrameData * data)
|
|||
#endif
|
||||
#if VA_CHECK_VERSION(1, 2, 0)
|
||||
case VA_FOURCC_Y210:
|
||||
case VA_FOURCC_Y216:
|
||||
data->Pitch = mem_id->image.pitches[0];
|
||||
data->Y = buf + mem_id->image.offsets[0];
|
||||
data->U = data->Y + 2;
|
||||
|
|
|
@ -64,6 +64,7 @@ static const struct fourcc_map gst_msdk_fourcc_mfx_to_va[] = {
|
|||
FOURCC_MFX_TO_VA (P010, P010),
|
||||
#if (MFX_VERSION >= 1031)
|
||||
FOURCC_MFX_TO_VA (P016, P016),
|
||||
FOURCC_MFX_TO_VA (Y216, Y216),
|
||||
#endif
|
||||
#if (MFX_VERSION >= 1028)
|
||||
FOURCC_MFX_TO_VA (RGB565, RGB565),
|
||||
|
|
Loading…
Reference in a new issue