g_mutex_lock (port->port_lock);
+ if (port->port_def.eDir == OMX_DirInput) {
+ /* Reset all flags, some implementations don't
+ * reset them themselves and the flags are not
+ * valid anymore after the buffer was consumed
+ */
+ buf->omx_buf->nFlags = 0;
+ }
+
if ((err = gst_omx_component_get_last_error (comp)) != OMX_ErrorNone) {
GST_ERROR_OBJECT (comp->parent, "Component is in error state: %s (0x%08x)",
gst_omx_error_to_string (err), err);
if (port->port_def.eDir == OMX_DirInput) {
err = OMX_EmptyThisBuffer (comp->handle, buf->omx_buf);
} else {
- /* Reset all flags, some implementations don't
- * reset them themselves and the flags are not
- * valid anymore after the buffer was consumed
- */
- buf->omx_buf->nFlags = 0;
err = OMX_FillThisBuffer (comp->handle, buf->omx_buf);
}