<div dir="ltr"><br><br><div class="gmail_quote">On Thu, Sep 4, 2008 at 1:54 PM, Wim Taymans <span dir="ltr"><<a href="mailto:wim.taymans@gmail.com">wim.taymans@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div class="Ih2E3d">On Thu, 2008-09-04 at 11:34 -0400, Tristan Matthews wrote:<br>
> Thanks for the feedback Eric. I had seen the RFC before but that book<br>
> looks pretty useful as well.<br>
> My concern isn't that the AV will get out of sync in<br>
> gstreamer/gstrtpbin, but rather that it will be out of sync immediately<br>
> at the capture stage, i.e. if i have video input from a camera with more<br>
> latency than a separate audio source. An example scenario is given here:<br>
> <a href="http://chris.pirillo.com/2007/07/11/audio-video-capture/" target="_blank">http://chris.pirillo.com/2007/07/11/audio-video-capture/</a><br>
> where you have video of someone clapping and you have to adjust the<br>
> delay to make the sound and image of the clap line up.<br>
> I would need to be able to manually adjust the latency to ensure the<br>
> video and audio are sync'd. Should I just put the audio through a<br>
> Ladspa-delay or is their a better solution in gstreamer?<br>
><br>
<br>
</div>This situation can not occur in gstreamer when you have a well written<br>
source element that generates correct timestamps and reports its latency<br>
correctly. You could write an element that applies an offset to all<br>
timestamps on the buffers.<br>
<font color="#888888"><br>
Wim<br>
</font><div><div></div><div class="Wj3C7c"></div></div></blockquote><div><br>AFAIK, This element already exists and is called GstShift from gentrans plugins<br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div><div class="Wj3C7c"><br>
<br>
> -T<br>
><br>
> Eric Zhang wrote:<br>
> > Hi, Tristan:<br>
> ><br>
> > You should not adjust video/audio latency manually because RTP<br>
> > provides a mechanism to accomplish this, called `lip-synchronization'.<br>
> > Refer to RFC 3550 or book `RTP: Video and Audio for the Internet' for<br>
> > more details. These will help you a lot.<br>
> ><br>
> > Eric Zhang<br>
> ><br>
> > 2008/9/3 Tristan Matthews <<a href="mailto:tristan@sat.qc.ca">tristan@sat.qc.ca</a> <mailto:<a href="mailto:tristan@sat.qc.ca">tristan@sat.qc.ca</a>>><br>
> ><br>
> > Hi,<br>
> ><br>
> > If I have a pipeline using gstrtpbin (similar to the example in the<br>
> > documentation) to send audio and video, what is the best/most reliable<br>
> > way of adding latency to the audio? Would gst_event_new_latency work<br>
> > (and if so, how), or am I missing its intent:<br>
> > <a href="http://gstreamer.freedesktop.org/data/doc/gstreamer/stable/gstreamer/html/gstreamer-GstEvent.html#gst-event-new-latency" target="_blank">http://gstreamer.freedesktop.org/data/doc/gstreamer/stable/gstreamer/html/gstreamer-GstEvent.html#gst-event-new-latency</a><br>
> ><br>
> > Basically my concern is that if video capture is too slow, can I<br>
> > manually adjust the audio latency to match.<br>
> ><br>
> > Best,<br>
> ><br>
> > Tristan<br>
> ><br>
> > --<br>
> > Tristan Matthews<br>
> > Société des arts technologiques [SAT]<br>
> > email: <a href="mailto:tristan@sat.qc.ca">tristan@sat.qc.ca</a> <mailto:<a href="mailto:tristan@sat.qc.ca">tristan@sat.qc.ca</a>><br>
> > web: <a href="http://www.music.mcgill.ca/%7Etmatthews" target="_blank">http://www.music.mcgill.ca/~tmatthews</a><br>
> > <<a href="http://www.music.mcgill.ca/%7Etmatthews" target="_blank">http://www.music.mcgill.ca/%7Etmatthews</a>><br>
> ><br>
> ><br>
> > -------------------------------------------------------------------------<br>
> > This SF.Net email is sponsored by the Moblin Your Move Developer's<br>
> > challenge<br>
> > Build the coolest Linux based applications with Moblin SDK & win<br>
> > great prizes<br>
> > Grand prize is a trip for two to an Open Source event anywhere in<br>
> > the world<br>
> > <a href="http://moblin-contest.org/redirect.php?banner_id=100&url=/" target="_blank">http://moblin-contest.org/redirect.php?banner_id=100&url=/</a><br>
> > <<a href="http://moblin-contest.org/redirect.php?banner_id=100&url=/" target="_blank">http://moblin-contest.org/redirect.php?banner_id=100&url=/</a>><br>
> > _______________________________________________<br>
> > gstreamer-devel mailing list<br>
> > <a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net</a><br>
> > <mailto:<a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net</a>><br>
> > <a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
> ><br>
> ><br>
> > ------------------------------------------------------------------------<br>
> ><br>
> > -------------------------------------------------------------------------<br>
> > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge<br>
> > Build the coolest Linux based applications with Moblin SDK & win great prizes<br>
> > Grand prize is a trip for two to an Open Source event anywhere in the world<br>
> > <a href="http://moblin-contest.org/redirect.php?banner_id=100&url=/" target="_blank">http://moblin-contest.org/redirect.php?banner_id=100&url=/</a><br>
> > ------------------------------------------------------------------------<br>
> ><br>
> > _______________________________________________<br>
> > gstreamer-devel mailing list<br>
> > <a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net</a><br>
> > <a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
> ><br>
><br>
><br>
<br>
<br>
-------------------------------------------------------------------------<br>
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge<br>
Build the coolest Linux based applications with Moblin SDK & win great prizes<br>
Grand prize is a trip for two to an Open Source event anywhere in the world<br>
<a href="http://moblin-contest.org/redirect.php?banner_id=100&url=/" target="_blank">http://moblin-contest.org/redirect.php?banner_id=100&url=/</a><br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.sourceforge.net">gstreamer-devel@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Thiago Sousa Santos<br><br>Embedded Systems and Pervasive Computing Lab (Embedded)<br>Center of Electrical Engineering and Informatics (CEEI)<br>Federal University of Campina Grande (UFCG)<br>
</div>