mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 12:11:13 +00:00
msdk: libva: Don't set the hint if MFX_VERSION is lower than 1025
MFX_MEMTYPE_VIDEO_MEMORY_ENCODER_TARGET is defined since MFX_VERSION 1025.
This commit is contained in:
parent
02a6a794ec
commit
acc14225c9
1 changed files with 2 additions and 0 deletions
|
@ -106,6 +106,7 @@ gst_msdk_frame_alloc (mfxHDL pthis, mfxFrameAllocRequest * req,
|
|||
num_attribs = 1;
|
||||
|
||||
/* set VA_SURFACE_ATTRIB_USAGE_HINT_ENCODER flag for encoding */
|
||||
#if (MFX_VERSION >= 1025)
|
||||
if ((req->Type & MFX_MEMTYPE_VIDEO_MEMORY_ENCODER_TARGET) &&
|
||||
(req->Type & MFX_MEMTYPE_FROM_ENCODE)) {
|
||||
attribs[1].type = VASurfaceAttribUsageHint;
|
||||
|
@ -114,6 +115,7 @@ gst_msdk_frame_alloc (mfxHDL pthis, mfxFrameAllocRequest * req,
|
|||
attribs[1].value.value.i = VA_SURFACE_ATTRIB_USAGE_HINT_ENCODER;
|
||||
num_attribs = 2;
|
||||
}
|
||||
#endif
|
||||
|
||||
format =
|
||||
gst_msdk_get_va_rt_format_from_mfx_rt_format (req->Info.ChromaFormat);
|
||||
|
|
Loading…
Reference in a new issue