<html><body><div style="color:#000; background-color:#fff; font-family:times new roman, new york, times, serif;font-size:12pt"><div><span></span></div><div><br></div>  <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div style="font-family: times new roman, new york, times, serif; font-size: 12pt;"> <div dir="ltr"> <hr size="1">  <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> Dave Milici <davemilici@sbcglobal.net><br> <b><span style="font-weight: bold;">To:</span></b> chaitanya v l <superchaits@gmail.com> <br> <b><span style="font-weight: bold;">Sent:</span></b> Thursday, October 3, 2013 6:36 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: querying playbin2 queue2 buffer stats<br> </font> </div> <div class="y_msg_container"><br>
<div id="yiv1767135887"><div><div style="color:#000;background-color:#fff;font-family:times new roman, new york, times, serif;font-size:12pt;"><div><span>The message handler for GST_MESSAGE_BUFFER events is not the most optimal place for tracking changes in 'current-level-bytes'. These buffering events occur relatively early in the stream playback process, so the levels seen are only in ~10K regions.</span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br><span></span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>When I enable GST_DEBUG=queue2:3 level console output, I get logging of 'current-level-bytes' climbing up to just under 2MB, although stream playback is noticeably impacted by this level of logging.</span></div><div style="
color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br><span></span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>When I try setting the current playbin2 object's 'buffer-size' property to 1MB, I see tracer for queue2 object's 'max-level-bytes' change to that value, but I still see GST_DEBUG logging for queue2 grow up to ~2MB!</span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br><span></span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>Is there more than one queue2 object used in a playbin2 pipeline?</span></div><div style="color:rgb(0, 0,
 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br><span></span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span>The only bin we customize for playbin2 is 'video-sink' for our device's video overlay window. We're not customizing the 'audio-sink' and using the libmad codec onboard now instead of the ffmpeg mp3 codec.</span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br><span> </span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;">Any other ideas on how keep the pipeline's buffering from blowing up?</div><div style="color:rgb(0, 0,
 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><br></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;">--Dave Milici<br><span></span></div><div style="color:rgb(0, 0, 0);font-size:16px;font-family:times new roman, new york, times, serif;background-color:transparent;font-style:normal;"><span><br></span></div>  <div style="font-family:times new roman, new york, times, serif;font-size:12pt;"> <div style="font-family:times new roman, new york, times, serif;font-size:12pt;"> <div dir="ltr"> <hr size="1">  <font face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> chaitanya v l <superchaits@gmail.com><br> <b><span style="font-weight:bold;">To:</span></b> Dave Milici <davemilici@sbcglobal.net> <br> <b><span style="font-weight:bold;">Sent:</span></b>
 Tuesday, October 1, 2013 9:48 PM<br> <b><span style="font-weight:bold;">Subject:</span></b> Re: querying playbin2 queue2 buffer stats<br> </font> </div> <div class="yiv1767135887y_msg_container"><br>
On Wed, Oct 2, 2013 at 12:40 AM, Dave Milici <<a rel="nofollow" ymailto="mailto:davemilici@sbcglobal.net" target="_blank" href="mailto:davemilici@sbcglobal.net">davemilici@sbcglobal.net</a>> wrote:<br>> OK, I can iterate through all the pipeline bin elements on video-changed and<br>> audio-changed callbacks, including queue2 object.<br>><br>> This media player already has a buffer message handler, so I'm wondering why<br>> the queue2 object is not accessible in that handler. Wouldn't that be the<br>> object which is posting GST_MESSAGE_BUFFER messages?<br>><br>> I'm trying to find a way to query and cap current-level-bytes since we have<br>> a really tight memory environment.<br>><br>current-level-* fields are read-only. You should try configuring<br>max-level-* fields instead.<br>Also, have you tried limiting the buffer size from playbin2 directly<br>using the buffer-size
 property?<br><br>regards,<br>Chaitanya<br><br><br></div> </div> </div> 
 </div></div></div><br><br></div> </div> </div>  </div></body></html>