diff --git a/gst-libs/gst/vaapi/gstvaapiencoder_objects.c b/gst-libs/gst/vaapi/gstvaapiencoder_objects.c index f31181e7f9..3227607c17 100644 --- a/gst-libs/gst/vaapi/gstvaapiencoder_objects.c +++ b/gst-libs/gst/vaapi/gstvaapiencoder_objects.c @@ -555,6 +555,10 @@ gst_vaapi_enc_picture_encode (GstVaapiEncPicture * picture) return FALSE; } + /* Submit Picture parameter */ + if (!do_encode (va_display, va_context, &picture->param_id, &picture->param)) + return FALSE; + /* Submit Misc Params */ for (i = 0; i < picture->misc_params->len; i++) { GstVaapiEncMiscParam *const misc = @@ -563,10 +567,6 @@ gst_vaapi_enc_picture_encode (GstVaapiEncPicture * picture) return FALSE; } - /* Submit Picture parameter */ - if (!do_encode (va_display, va_context, &picture->param_id, &picture->param)) - return FALSE; - /* Submit Slice parameters */ for (i = 0; i < picture->slices->len; i++) { GstVaapiEncSlice *const slice = g_ptr_array_index (picture->slices, i);