<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Hi,<div class=""><br class=""></div><div class=""><div class=""><br class=""></div><div class="">I refactored my project based on Tim's examples, which works perfectly when the pipeline contains only a video source, although I found one strange thing in the behaviour: </div><div class="">the blocking of a pad work only in cases when there is a "tee" between the source and the blocked element, otherwise it will block the other parts of the pipeline (so I added on extra(unnecessary?) tee for the audio). Is this expected or I do something not properly? </div><div class=""><br class=""></div><div class="">But when I add an audio source things are getting a bit more complicated.</div><div class=""><br class=""></div><div class="">So I added the audio and moved the cacheing/buffering queue after the muxer () . But this way it generates invalid file on the output (VLC show this kind of issues: "ps warning: this does not look like an MPEG PS stream, continuing anyway; ps warning: garbage at input from 509, trying to resync...")</div><div class=""><br class=""></div><div class=""><div style="color: rgb(54, 54, 54); background-color: rgb(255, 255, 255); font-family: Menlo, Monaco, "Courier New", monospace; font-weight: 800; font-size: 10px; line-height: 15px; white-space: pre;" class=""><div class=""><span style="color: rgb(162, 86, 55);" class="">nvarguscamerasrc sensor-id=0 sensor-mode=0</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> ! video/x-raw(memory:NVMM), width=(int)1980, height=(int)1080, format=(string)NV12, framerate=(fraction)20/1 </span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> ! nvvidconv ! textoverlay name=text_overlay ! video/x-raw,format=I420 ! nvvidconv ! nvv4l2vp8enc ! tee name=video_stream_spilt</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> audiotestsrc ! vorbisenc ! queue ! file_sink_video_mux.</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> video_stream_spilt. ! queue ! webmmux name=file_sink_video_mux ! tee name=muxed_video_stream_spilt</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> muxed_video_stream_spilt. ! queue name=file_sink_queue ! filesink name=file_sink location=/tmp/video_out.webm</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> muxed_video_stream_spilt. ! fakesink</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> video_stream_spilt. ! rtpvp8pay mtu=1400 ! appsink name=app_sink</span></div></div></div><div class=""><br class=""></div><div class="">I tried to google around, but I not found any similar examples so I guess I cannot "buffer" muxed packets with a queue. Is this approach fundamentally wrong?</div><div class=""><br class=""></div><div class="">After this I tried to add queues before the mux, but this way the pipeline stops when Im unblocking the pads. <br class=""><div><br class=""></div><div><div style="color: rgb(54, 54, 54); background-color: rgb(255, 255, 255); font-family: Menlo, Monaco, "Courier New", monospace; font-weight: 800; font-size: 10px; line-height: 15px; white-space: pre;" class=""><div class=""><span style="caret-color: rgb(162, 86, 55); color: rgb(162, 86, 55);" class="">nvarguscamerasrc sensor-id=0 sensor-mode=0</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> </span><span style="caret-color: rgb(162, 86, 55); color: rgb(162, 86, 55);" class="">! video/x-raw(memory:NVMM), width=(int)1980, height=(int)1080, format=(string)NV12, framerate=(fraction)20/1 </span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> ! nvvidconv ! textoverlay name=text_overlay ! video/x-raw,format=I420 ! nvvidconv ! nvv4l2vp8enc ! tee name=video_stream_spilt </span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> audiotestsrc ! vorbisenc ! tee name=audio_stream_spilt</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> audio_stream_spilt. ! queue name=file_sink_audio_queue ! file_sink_video_mux.</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> audio_stream_spilt. ! fakesink</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> video_stream_spilt. ! queue name=file_sink_video_queue ! webmmux name=file_sink_video_mux ! filesink name=file_sink location=/tmp/video_out.webm</span></div><div class=""><span style="color: rgb(162, 86, 55);" class=""> video_stream_spilt. ! rtpvp8pay mtu=1400 ! appsink name=app_sink</span></div></div></div><div><br class=""></div><div>I will attach the debug output, the corresponding part comes after the "<span style="color: rgb(54, 54, 54); font-family: Menlo, Monaco, "Courier New", monospace; font-size: 10px; font-weight: 800; white-space: pre; background-color: rgb(255, 255, 255);" class="">startRecording: dcd - startRecording</span>" log message. Im sure that im doing something wrong, since I think this should work. </div><div><br class=""></div><div>Do you have any idea what am I doing wrong?</div><div><br class=""></div><div>Thank you!</div><div><br class=""></div><div></div></div></div></body></html>