[gst-devel] Specifying video record interval

Demon Deng dxssx.dxssx at gmail.com
Tue Mar 9 02:12:13 CET 2010


num-buffers also works for audio src, add it to pulsesrc

2010/3/9 Pavel Johnson <pavel.johnson at gmail.com>

> Thanks!  The num-buffers parameter helps and the video stops recording,
> however, the command pipeline I have (included below) continues recording
> audio.  Is there a parameter to specify audio-time as well?  Ideally, a
> single parameter for specifying the time for both audio and video would be
> preferred by separate ones are OK as well.
>
> Also, I would hope the pipeline would terminate automatically so that it
> can be scripted.
>
>
> gst-launch v4l2src ! 'video/x-raw-yuv,width=640,
> height=480,framerate=30/1' ! \
> tee name=t_vid ! queue ! videoflip method=horizontal-flip ! \
> xvimagesink sync=false t_vid. ! queue ! \
> videorate ! 'video/x-raw-yuv,framerate=30/1' ! queue ! mux. \
> pulsesrc ! audio/x-raw-int,rate=22000,channels=1,width=16 ! queue ! \
> audioconvert ! queue ! mux. avimux name=mux ! \
> filesink location=/test.mpg
>
> Thanks,
> ~Pavel
>
>
> On Sun, Mar 7, 2010 at 7:30 PM, sudarshan bisht <bisht.sudarshan at gmail.com
> > wrote:
>
>> Hi ,
>>       you can set "num-buffers" in v4l2src element , and I think number of
>> buffers will depend on the framerate (fps)  and the time duration ( in
>> seconds) .
>>
>>       Suppose fps is 30 frame/sec and the time duration is 30 secs then
>> num-buffers will be 30*30 = 900 .
>>
>>       Try this out .
>>
>> On Mon, Mar 8, 2010 at 4:32 AM, Pavel Johnson <pavel.johnson at gmail.com>wrote:
>>
>>> Hello,
>>>
>>> I am new to Gstreamer so please bear with me if this has been addressed.
>>>
>>> I am trying to record video from a webcam using the command line below
>>> and would like to specify the duration for which the video/audio needs to be
>>> recorded, i.e. the command below should terminate after say 30 sec of
>>> recording.  What command options and where in the command line can the
>>> recording duration be included?  If there is no option, what tools are
>>> available to achieve this?
>>>
>>> gst-launch v4l2src !
>>> 'video/x-raw-yuv,width=640,height=480,framerate=30/1' ! \
>>> tee name=t_vid ! queue ! videoflip method=horizontal-flip ! \
>>> xvimagesink sync=false t_vid. ! queue ! \
>>> videorate ! 'video/x-raw-yuv,framerate=30/1' ! queue ! mux. \
>>> pulsesrc ! audio/x-raw-int,rate=22000,channels=1,width=16 ! queue ! \
>>> audioconvert ! queue ! mux. avimux name=mux ! \
>>> filesink location=/test.mpg
>>>
>>> TIA,
>>> Pavel
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Download Intel&#174; Parallel Studio Eval
>>> Try the new software tools for yourself. Speed compiling, find bugs
>>> proactively, and fine-tune applications for parallel performance.
>>> See why Intel Parallel Studio got high marks during beta.
>>> http://p.sf.net/sfu/intel-sw-dev
>>> _______________________________________________
>>> gstreamer-devel mailing list
>>> gstreamer-devel at lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>>>
>>>
>>
>>
>> --
>> Regards,
>>
>> Sudarshan Bisht
>>
>>
>> ------------------------------------------------------------------------------
>> Download Intel&#174; Parallel Studio Eval
>> Try the new software tools for yourself. Speed compiling, find bugs
>> proactively, and fine-tune applications for parallel performance.
>> See why Intel Parallel Studio got high marks during beta.
>> http://p.sf.net/sfu/intel-sw-dev
>> _______________________________________________
>> gstreamer-devel mailing list
>> gstreamer-devel at lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>>
>>
>
>
> ------------------------------------------------------------------------------
> Download Intel&#174; Parallel Studio Eval
> Try the new software tools for yourself. Speed compiling, find bugs
> proactively, and fine-tune applications for parallel performance.
> See why Intel Parallel Studio got high marks during beta.
> http://p.sf.net/sfu/intel-sw-dev
> _______________________________________________
> 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/20100309/1eef3a6a/attachment.htm>


More information about the gstreamer-devel mailing list