[Gstreamer-openmax] [PATCH 08/10] add some debug traces
Rob Clark
rob at ti.com
Sun Mar 7 15:14:55 PST 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 02cacaa..7f3e536 100644
--- a/omx/gstomx_base_filter.c
+++ b/omx/gstomx_base_filter.c
@@ -75,6 +75,7 @@ setup_ports (GstOmxBaseFilter *self)
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;
@@ -82,14 +83,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 128f06a..565bdda 100644
--- a/omx/gstomx_util.c
+++ b/omx/gstomx_util.c
@@ -628,6 +628,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,
@@ -638,6 +639,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