Commit 24ca8ab8 authored by Martin Storsjö's avatar Martin Storsjö

omxil: vout: Factorize fifo init/destroy

Signed-off-by: default avatarMartin Storsjö <martin@martin.st>
parent 7d062555
......@@ -179,10 +179,7 @@ static int Open(vlc_object_t *p_this)
p_sys->psz_component, omx_error, ErrorToString(omx_error));
InitOmxEventQueue(&p_sys->event_queue);
vlc_mutex_init (&p_sys->port.fifo.lock);
vlc_cond_init (&p_sys->port.fifo.wait);
p_sys->port.fifo.offset = offsetof(OMX_BUFFERHEADERTYPE, pOutputPortPrivate) / sizeof(void *);
p_sys->port.fifo.pp_last = &p_sys->port.fifo.p_first;
OMX_FIFO_INIT(&p_sys->port.fifo, pOutputPortPrivate);
p_sys->port.b_direct = false;
p_sys->port.b_flushed = true;
......@@ -373,8 +370,7 @@ static void Close(vlc_object_t *p_this)
free(p_sys->port.pp_buffers);
pf_free_handle(p_sys->omx_handle);
DeinitOmxEventQueue(&p_sys->event_queue);
vlc_mutex_destroy(&p_sys->port.fifo.lock);
vlc_cond_destroy(&p_sys->port.fifo.wait);
OMX_FIFO_DESTROY(&p_sys->port.fifo);
}
if (p_sys->pool)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment