encoder: re-order submission of VA objects.

Change the submission order of VA objects so that to make that process
more logical. i.e. submit sequence parameter first, if any; next the
packed headers associated to sequece, picture or slices; and finally
the actual picture and associated slices.
This commit is contained in:
Gwenole Beauchesne 2014-01-14 13:47:52 +01:00
parent d45c6a486f
commit c03682ecc1

View file

@ -423,10 +423,6 @@ gst_vaapi_enc_picture_encode (GstVaapiEncPicture * picture)
&sequence->param_id, &sequence->param))
return FALSE;
/* Submit Picture parameter */
if (!do_encode (va_display, va_context, &picture->param_id, &picture->param))
return FALSE;
/* Submit Packed Headers */
for (i = 0; i < picture->packed_headers->len; i++) {
GstVaapiEncPackedHeader *const header =
@ -445,6 +441,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 Slice parameters */
for (i = 0; i < picture->slices->len; i++) {
GstVaapiEncSlice *const slice = g_ptr_array_index (picture->slices, i);