[Gstreamer-openmax] [PATCH 7/8] Add some debug traces
Rob Clark
rob at ti.com
Wed Mar 17 16:59:00 PDT 2010
---
omx/gstomx_base_filter.c | 12 ++++++++++++
omx/gstomx_util.c | 2 ++
2 files changed, 14 insertions(+), 0 deletions(-)
diff --git a/omx/gstomx_base_filter.c b/omx/gstomx_base_filter.c
index 76ec085..3f6677f 100644
--- a/omx/gstomx_base_filter.c
+++ b/omx/gstomx_base_filter.c
@@ -63,6 +63,7 @@ setup_ports (GstOmxBaseFilter *self)
/* @todo: read from config file: */
if (g_getenv ("OMX_ALLOCATE_ON"))
{
+ GST_DEBUG_OBJECT (self, "OMX_ALLOCATE_ON");
self->in_port->omx_allocate = TRUE;
self->out_port->omx_allocate = TRUE;
self->share_input_buffer = FALSE;
@@ -70,14 +71,25 @@ setup_ports (GstOmxBaseFilter *self)
}
else if (g_getenv ("OMX_SHARE_HACK_ON"))
{
+ GST_DEBUG_OBJECT (self, "OMX_SHARE_HACK_ON");
self->share_input_buffer = TRUE;
self->share_output_buffer = TRUE;
}
else if (g_getenv ("OMX_SHARE_HACK_OFF"))
{
+ GST_DEBUG_OBJECT (self, "OMX_SHARE_HACK_OFF");
self->share_input_buffer = FALSE;
self->share_output_buffer = FALSE;
}
+ else
+ {
+ GST_DEBUG_OBJECT (self, "default sharing and allocation");
+ }
+
+ GST_DEBUG_OBJECT (self, "omx_allocate: in: %d, out: %d",
+ self->in_port->omx_allocate, self->out_port->omx_allocate);
+ GST_DEBUG_OBJECT (self, "share_buffer: in: %d, out: %d",
+ self->share_input_buffer, self->share_output_buffer);
}
static GstStateChangeReturn
diff --git a/omx/gstomx_util.c b/omx/gstomx_util.c
index 103c919..1fe0722 100644
--- a/omx/gstomx_util.c
+++ b/omx/gstomx_util.c
@@ -586,6 +586,7 @@ port_allocate_buffers (GOmxPort *port)
{
if (port->omx_allocate)
{
+ GST_DEBUG_OBJECT (port->core->object, "%d: OMX_AllocateBuffer(), size=%"G_GSIZE_FORMAT, i, size);
OMX_AllocateBuffer (port->core->omx_handle,
&port->buffers[i],
port->port_index,
@@ -596,6 +597,7 @@ port_allocate_buffers (GOmxPort *port)
{
gpointer buffer_data;
buffer_data = g_malloc (size);
+ GST_DEBUG_OBJECT (port->core->object, "%d: OMX_UseBuffer(), size=%"G_GSIZE_FORMAT, i, size);
OMX_UseBuffer (port->core->omx_handle,
&port->buffers[i],
port->port_index,
--
1.6.3.2
More information about the Gstreamer-openmax
mailing list