imagefreeze + leaky queue problem

mariannasb mariannasb at yahoo.com.br
Thu Jun 9 07:10:02 UTC 2016


The following pipeline works fine (you can see the time overlay increment
over the image):

gst-launch-1.0 filesrc location = Toddy_Dog.jpg ! jpegdec ! imagefreeze !
video/x-raw,framerate=25/1 ! queue leaky=0 ! timeoverlay ! videoconvert !
ximagesink

However if the queue is set to leak (leaky=2 for example), then the time
overlay remains static (sometimes at 0, sometimes slightly above 0).

gst-launch-1.0 filesrc location = Toddy_Dog.jpg ! jpegdec ! imagefreeze !
video/x-raw,framerate=25/1 ! queue leaky=2 ! timeoverlay ! videoconvert !
ximagesink

If I set the ximagesink to not synch to the clock then it runs (the time
overlay increments very fast though, and jumps a lot of values)

gst-launch-1.0 filesrc location = Toddy_Dog.jpg ! jpegdec ! imagefreeze !
video/x-raw,framerate=25/1 ! queue leaky=2 ! timeoverlay ! videoconvert !
ximagesink sync=0

By setting the debug levels I can see that the problem is the imagefreeze
increment the timestamp way too fast (it moves in increments corresponding
to the fps, but it is not following the clock).
It seems to me that it tries to push buffers as fast as it can, incrementing
the timestamp by the fps interval each time, and since the queue leaks it
manages to do it way faster than it should...

leaky=2
0:00:02.896600487  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.896627831  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:05:31.240000000
0:00:02.896668265  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:05:31.000000000
0:00:02.896695127  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.896713673  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.240000000, src
+0:05:31.000000000
0:00:02.896743225  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:05:31.280000000
0:00:02.896773253  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.896791620  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.280000000, src
+0:05:31.000000000
0:00:02.896826545  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.896852845  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:05:31.280000000
0:00:02.896884538  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:05:31.040000000
0:00:02.896920127  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.896938885  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.280000000, src
+0:05:31.040000000
0:00:02.896968525  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:05:31.320000000
0:00:02.896998602  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.897017500  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.320000000, src
+0:05:31.040000000
0:00:02.897048260  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.897078787  1127 0x7f5d80002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:05:31.320000000
0:00:02.897111776  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:05:31.080000000
0:00:02.897143436  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.897162355  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.320000000, src
+0:05:31.080000000
0:00:02.897191707  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:05:31.360000000
0:00:02.897216889  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.897239100  1127 0x7f5d80002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:05:31.360000000, src
+0:05:31.080000000

leaky=0
0:00:02.431847454  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.431942959  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:00:02.160000000
0:00:02.435804127  1151       0x6d1140 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:00:01.920000000
0:00:02.435882275  1151       0x6d1140 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.435904795  1151       0x6d1140 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.160000000, src
+0:00:01.920000000
0:00:02.436187015  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:00:02.200000000
0:00:02.436256229  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.436286151  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.200000000, src
+0:00:01.920000000
0:00:02.436348700  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.436399989  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:00:02.200000000
0:00:02.440459636  1151       0x6d1140 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:00:01.960000000
0:00:02.440537181  1151       0x6d1140 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.440555883  1151       0x6d1140 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.200000000, src
+0:00:01.960000000
0:00:02.440641952  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:00:02.240000000
0:00:02.440710638  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.440740579  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.240000000, src
+0:00:01.960000000
0:00:02.440802398  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:799:gst_image_freeze_src_loop:<imagefreeze0:src> Pushing
buffer resulted in ok
0:00:02.440850154  1151 0x7f1b28002b70 DEBUG            imagefreeze
gstimagefreeze.c:789:gst_image_freeze_src_loop:<imagefreeze0:src> Handling
buffer with timestamp 0:00:02.240000000
0:00:02.444847291  1151       0x6d1140 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> src position updated to
0:00:02.000000000
0:00:02.444959686  1151       0x6d1140 LOG                    queue
gstqueue.c:538:update_time_level:<queue0> update src time
0:00:02.444983815  1151       0x6d1140 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.240000000, src
+0:00:02.000000000
0:00:02.445285033  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:633:apply_buffer:<queue0> sink position updated to
0:00:02.280000000
0:00:02.445393011  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:529:update_time_level:<queue0> update sink time
0:00:02.445426857  1151 0x7f1b28002b70 LOG                    queue
gstqueue.c:547:update_time_level:<queue0> sink +0:00:02.280000000, src
+0:00:02.000000000

Am I missing something or is this a bug?




--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/imagefreeze-leaky-queue-problem-tp4677950.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list