[0.11] gstreamer: bufferpool: add some more debug info

Wim Taymans wtay at kemper.freedesktop.org
Fri Mar 4 07:18:51 PST 2011


Module: gstreamer
Branch: 0.11
Commit: dbcb6eee721bdd2c64b592a7a7faf9f85cef25fb
URL:    http://cgit.freedesktop.org/gstreamer/gstreamer/commit/?id=dbcb6eee721bdd2c64b592a7a7faf9f85cef25fb

Author: Wim Taymans <wim.taymans at collabora.co.uk>
Date:   Thu Mar  3 18:21:31 2011 +0100

bufferpool: add some more debug info

---

 gst/gstbufferpool.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/gst/gstbufferpool.c b/gst/gstbufferpool.c
index 46d8150..aa44569 100644
--- a/gst/gstbufferpool.c
+++ b/gst/gstbufferpool.c
@@ -197,6 +197,7 @@ default_start (GstBufferPool * pool)
     if (pclass->alloc_buffer (pool, &buffer, NULL) != GST_FLOW_OK)
       goto alloc_failed;
 
+    GST_LOG_OBJECT (pool, "prealloced buffer %d: %p", i, buffer);
     /* store in the queue */
     gst_atomic_queue_push (pool->queue, buffer);
     gst_poll_write_control (pool->poll);
@@ -225,6 +226,7 @@ do_start (GstBufferPool * pool)
 
     pclass = GST_BUFFER_POOL_GET_CLASS (pool);
 
+    GST_LOG_OBJECT (pool, "starting");
     /* start the pool, subclasses should allocate buffers and put them
      * in the queue */
     if (G_LIKELY (pclass->start)) {
@@ -271,6 +273,7 @@ do_stop (GstBufferPool * pool)
 
     pclass = GST_BUFFER_POOL_GET_CLASS (pool);
 
+    GST_LOG_OBJECT (pool, "stopping");
     if (G_LIKELY (pclass->stop)) {
       if (!pclass->stop (pool))
         return FALSE;
@@ -301,6 +304,8 @@ gst_buffer_pool_set_active (GstBufferPool * pool, gboolean active)
 
   pclass = GST_BUFFER_POOL_GET_CLASS (pool);
 
+  GST_LOG_OBJECT (pool, "active %d", active);
+
   GST_BUFFER_POOL_LOCK (pool);
   /* just return if we are already in the right state */
   if (pool->active == active)



More information about the gstreamer-commits mailing list