qsvencoder: Don't use USAGE_HINT_ENCODER and enable derived image support

Peformance issue by disabled derived image support was reported

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/2111>
This commit is contained in:
Seungha Yang 2022-04-04 20:47:03 +09:00 committed by GStreamer Marge Bot
parent b74da32b5c
commit 26fa35dcdf

View file

@ -893,7 +893,7 @@ gst_qsv_encoder_prepare_va_pool (GstQsvEncoder * self,
priv->internal_pool = gst_va_pool_new_with_config (caps, priv->internal_pool = gst_va_pool_new_with_config (caps,
GST_VIDEO_INFO_SIZE (aligned_info), 0, 0, GST_VIDEO_INFO_SIZE (aligned_info), 0, 0,
VA_SURFACE_ATTRIB_USAGE_HINT_ENCODER, GST_VA_FEATURE_DISABLED, VA_SURFACE_ATTRIB_USAGE_HINT_GENERIC, GST_VA_FEATURE_AUTO,
allocator, &params); allocator, &params);
gst_object_unref (allocator); gst_object_unref (allocator);
@ -1479,12 +1479,9 @@ gst_qsv_encoder_propose_allocation (GstVideoEncoder * encoder, GstQuery * query)
return FALSE; return FALSE;
} }
/* Will not use derived image
* https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1110
*/
pool = gst_va_pool_new_with_config (caps, pool = gst_va_pool_new_with_config (caps,
GST_VIDEO_INFO_SIZE (&info), priv->surface_pool->len, 0, GST_VIDEO_INFO_SIZE (&info), priv->surface_pool->len, 0,
VA_SURFACE_ATTRIB_USAGE_HINT_ENCODER, GST_VA_FEATURE_DISABLED, VA_SURFACE_ATTRIB_USAGE_HINT_GENERIC, GST_VA_FEATURE_AUTO,
allocator, &params); allocator, &params);
if (!pool) { if (!pool) {