omxvideoenc: update local port_def after reopening the component

gst_omx_video_enc_open will only update GstOMXVideoEnc->port->port_def.

Note that the component is reopen only if the flag
GST_OMX_HACK_NO_COMPONENT_RECONFIGURE is set.

https://bugzilla.gnome.org/show_bug.cgi?id=782418
This commit is contained in:
Julien Isorce 2017-07-05 10:48:52 +01:00
parent ebc9b4903c
commit 786a2617b2

View file

@ -989,6 +989,9 @@ gst_omx_video_enc_set_format (GstVideoEncoder * encoder,
if (!gst_omx_video_enc_open (GST_VIDEO_ENCODER (self)))
return FALSE;
needs_disable = FALSE;
/* The local port_def is now obsolete so get it again. */
gst_omx_port_get_port_definition (self->enc_in_port, &port_def);
} else {
if (gst_omx_port_set_enabled (self->enc_in_port, FALSE) != OMX_ErrorNone)
return FALSE;