[gst-devel] Slight audio/video sync problem - any suggestions?

Jason L. Buberel jason at buberel.org
Wed Mar 5 17:44:55 CET 2008


Thanks to Mark for his wonderful gentrans plugin, I have declared success!

You can read all about it at: http://www.buberel.org/serendipity/

The short version is that I now have a working gstreamer-based command 
that will capture very high quality video (high resolution, very few 
compression artifacts) and audio with near perfect audio/video sync 
using Theora/Vorbis/Ogg encoding. The resulting output can then be 
uploaded DIRECTLY to YouTube and plays back flawlessly.

All of this using nothing more than a cheap USB webcam on Ubuntu.

-Jason


Mark Nauwelaerts wrote:
> Well, I know :) , "stamp" never has been.  That is, it is not part of a usual
> distro GStreamer installation (involving core, gst-plugins-good, etc).
> However, it is part of the gst-entrans collection also found at the given
> sourceforge URL (which would then require download, compiling, etc).
> You might do a temporary proof-of-concept (sort of) test instead that forces a
> copy using:
> - efence; pretty abusive and hits memory a bit
> - a combination of 2 x videocrop (adding and dropping a mock border)
> - some other creative combination ...
>
> However, neither of these has any of stamp's "fancy sync features" (if that's
> what you refer to), which is why it was made ...
>
> Regards,
> Mark.
>
> Jason L. Buberel wrote:
>   
>> Ack - that feels SOO CLOSE to what I need. Unfortunately, the element
>> being discussed - 'stamp' - no longer appears to be part of gstreamer v0.10:
>>
>> WARNING: erroneous pipeline: no element "stamp"
>>
>> And sure enough 'gst-inspect' does not include any reference to a
>> 'stamp' element either.
>>
>> I shall keep digging!
>>
>> -jason
>>
>> Mark Nauwelaerts wrote:
>>     
>>> This could be another example of what is mentioned in the Note at the end of
>>> section
>>> http://gentrans.sourceforge.net/docs/head/manual/html/howto.html#sect-recording
>>> (observe that introducing a queue actually entails a "separate thread", as it is
>>> mentioned in this context).
>>>
>>> In itself, that may not provide more of an explanation :-(,
>>> but may give some ideas/inspiration to variations/alternatives.
>>>
>>> Regards,
>>> Mark.
>>>
>>> Jason L. Buberel wrote:
>>>   
>>>       
>>>> Oddly enough, that makes things worse :(
>>>>
>>>> Here is what I have confirmed - the following command will result in a
>>>> VERY clear high quality audio-only recording on my configuration:
>>>>
>>>>     
>>>>         
>>>>> gst-launch-0.10 alsasrc device="hw:1,0" !
>>>>>       
>>>>>           
>>>> audio/x-raw-int,rate=16000,channels=1,depth=16 ! audioconvert !
>>>> vorbisenc ! oggmux ! filesink location=audio-only.ogg
>>>>
>>>> Which you can hear:
>>>>
>>>> http://www.buberel.org/audio-only.ogg
>>>>
>>>> But when I use Nei's command below, which has essentially the same audio
>>>> parameters but with the additional 'queue' element to record audio and
>>>> video, I see many of the following error messages:
>>>>
>>>> WARNING: from element /pipeline0/alsasrc0: Can't record audio fast enough
>>>> Additional debug info:
>>>> gstbaseaudiosrc.c(603): gst_base_audio_src_create (): /pipeline0/alsasrc0:
>>>> dropped 13600 samples
>>>> WARNING: from element /pipeline0/alsasrc0: Can't record audio fast enough
>>>> Additional debug info:
>>>> gstbaseaudiosrc.c(603): gst_base_audio_src_create (): /pipeline0/alsasrc0:
>>>> dropped 12000 samples
>>>> WARNING: from element /pipeline0/alsasrc0: Can't record audio fast enough
>>>> Additional debug info:
>>>>
>>>> I am going to work on an ascii-art diagram of this pipeline in the hopes
>>>> that it will help others see the mistake I am making.
>>>>
>>>> -jason
>>>>
>>>>
>>>> Nie Jun wrote:
>>>>     
>>>>         
>>>>> gst-launch-0.10 v4l2src ! queue ! videorate !
>>>>> video/x-raw-yuv,width=800,height=600,framerate=15/1  !
>>>>> ffmpegcolorspace ! theoraenc ! queue ! oggmux name=mux alsasrc
>>>>> device="hw:1,0"  ! audiorate !
>>>>> audio/x-raw-int,rate=16000,channels=1,depth=16 ! queue ! audioconvert
>>>>> ! vorbisenc ! QUEUE ! mux. mux. ! queue ! filesink sync=true
>>>>> location=test.ogg
>>>>>
>>>>> hope it helps you.
>>>>>   
>>>>>       
>>>>>           
>>>> ------------------------------------------------------------------------
>>>>
>>>> -------------------------------------------------------------------------
>>>> This SF.net email is sponsored by: Microsoft
>>>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>>>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>>>>
>>>>
>>>> ------------------------------------------------------------------------
>>>>
>>>> _______________________________________________
>>>> gstreamer-devel mailing list
>>>> gstreamer-devel at lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>>>>     
>>>>         
>> ------------------------------------------------------------------------
>>
>> -------------------------------------------------------------------------
>> This SF.net email is sponsored by: Microsoft
>> Defy all challenges. Microsoft(R) Visual Studio 2008.
>> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
>>
>>
>> ------------------------------------------------------------------------
>>
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>>     
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20080305/350b0b51/attachment.htm>


More information about the gstreamer-devel mailing list