summaryrefslogtreecommitdiff
path: root/omx/gstomx.h
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2018-08-13 15:10:37 +0200
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2018-08-30 10:59:30 +0200
commit34bc02e397d8db72c06d86f7a8734c0d34d78276 (patch)
tree99e0ff396abf4cfc81b57ef6ac4f199e713942d9 /omx/gstomx.h
parentc89b54fe7867568f85ccc3b8660bbbd839659fcd (diff)
downloadgst-omx-34bc02e397d8db72c06d86f7a8734c0d34d78276.tar.gz
omx: allow gst_omx_port_acquire_buffer() to not wait for buffers
Will be needed to implement GST_BUFFER_POOL_ACQUIRE_FLAG_DONTWAIT. https://bugzilla.gnome.org/show_bug.cgi?id=796918
Diffstat (limited to 'omx/gstomx.h')
-rw-r--r--omx/gstomx.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/omx/gstomx.h b/omx/gstomx.h
index cab62bd..c43e2d7 100644
--- a/omx/gstomx.h
+++ b/omx/gstomx.h
@@ -225,7 +225,9 @@ typedef enum {
/* The port is EOS */
GST_OMX_ACQUIRE_BUFFER_EOS,
/* A fatal error happened */
- GST_OMX_ACQUIRE_BUFFER_ERROR
+ GST_OMX_ACQUIRE_BUFFER_ERROR,
+ /* No buffer is currently available (used when calling gst_omx_port_acquire_buffer() in not waiting mode) */
+ GST_OMX_ACQUIRE_BUFFER_NO_AVAILABLE,
} GstOMXAcquireBufferReturn;
struct _GstOMXCore {
@@ -269,6 +271,11 @@ typedef enum {
GST_OMX_BUFFER_ALLOCATION_USE_BUFFER_DYNAMIC, /* Only supported by OMX 1.2.0 */
} GstOMXBufferAllocation;
+typedef enum {
+ GST_OMX_WAIT,
+ GST_OMX_DONT_WAIT,
+} GstOMXWait;
+
struct _GstOMXMessage {
GstOMXMessageType type;
@@ -441,7 +448,7 @@ OMX_ERRORTYPE gst_omx_close_tunnel (GstOMXPort * port1, GstOMXPort * port2);
OMX_ERRORTYPE gst_omx_port_get_port_definition (GstOMXPort * port, OMX_PARAM_PORTDEFINITIONTYPE * port_def);
OMX_ERRORTYPE gst_omx_port_update_port_definition (GstOMXPort *port, OMX_PARAM_PORTDEFINITIONTYPE *port_definition);
-GstOMXAcquireBufferReturn gst_omx_port_acquire_buffer (GstOMXPort *port, GstOMXBuffer **buf);
+GstOMXAcquireBufferReturn gst_omx_port_acquire_buffer (GstOMXPort *port, GstOMXBuffer **buf, GstOMXWait wait);
OMX_ERRORTYPE gst_omx_port_release_buffer (GstOMXPort *port, GstOMXBuffer *buf);
OMX_ERRORTYPE gst_omx_port_set_flushing (GstOMXPort *port, GstClockTime timeout, gboolean flush);