How to stop multifilesink pipeline

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

How to stop multifilesink pipeline

Farzan
Hi,
I am new to Gstreamer, can anyone tell me how to set a timer or max number of files to end the following pipeline

gst-launch-0.10  v4l2src ! jpegenc ! multifilesink location="frame%d.jpg"

For example if I need only 10 frames what do I need to keep the pipeline from going on and stop after taking 10 frames.
Reply | Threaded
Open this post in threaded view
|

Re: How to stop multifilesink pipeline

Tim Müller
On Tue, 2017-07-04 at 03:58 -0700, Farzan wrote:

Hi,

> I am new to Gstreamer, can anyone tell me how to set a timer or max
> number of files to end the following pipeline
>
> gst-launch-0.10  v4l2src ! jpegenc ! multifilesink
> location="frame%d.jpg"
>
> For example if I need only 10 frames what do I need to keep the
> pipeline from going on and stop after taking 10 frames.

You can use

  v4l2src num-buffers=10 ! ..

if you want to stop after 10 frames (not so easy to specify in time
units).

Also, please note that GStreamer 0.10 is ancient and unmaintained, you
should really upgrade to 1.0 instead.

Cheers
 -Tim

--
Tim Müller, Centricular Ltd - http://www.centricular.com

Join us at the GStreamer Conference!
21-22 October 2017 in Prague, Czech Republic
http://gstreamer.freedesktop.org/conference/
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: How to stop multifilesink pipeline

Guillaume Desmottes
In reply to this post by Farzan
Hi Farzan,

"v4l2src num-buffers=10" should do the trick I think.


     G.


On 04/07/2017 12:58, Farzan wrote:

> Hi,
> I am new to Gstreamer, can anyone tell me how to set a timer or max number
> of files to end the following pipeline
>
> gst-launch-0.10  v4l2src ! jpegenc ! multifilesink location="frame%d.jpg"
>
> For example if I need only 10 frames what do I need to keep the pipeline
> from going on and stop after taking 10 frames.
>
>
>
>
> --
> View this message in context: http://gstreamer-devel.966125.n4.nabble.com/How-to-stop-multifilesink-pipeline-tp4683677.html
> Sent from the GStreamer-devel mailing list archive at Nabble.com.
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: How to stop multifilesink pipeline

Farzan
In reply to this post by Tim Müller
Thank you for the reply. Using num-buffers=10 works but there is one problem at times it captures less than 10 images. Do you know the reason why?

Regards,
Farzan Zaheer