Taking a snapshot image.

Robin gstreamerdeveloper at gmail.com
Mon Apr 16 07:09:36 PDT 2012


Hi,

I’ve setup a pipeline with two bins attached to a tee.  The first bin is simply for display (queue –> DirectDraw).  The second bin has a pipeline appropriate for writing a PNG (using pngenc), followed by a multifilesink.

My idea was that I could perhaps set some properties on the PNG element, or the file sink, to tell it to just capture 1 image, or capture 10 images at 1/25 (or whatever) and those images would then appear in the given directory.

For the single image case, I set snapshot to true on the pngenc.  This correctly took one image but it then managed to set the entire pipeline into an EOS state.  When I’m done, I unlink the pngend bin off the tee of course, but when I reattach it to take another snapshot, it doesn’t work (not the reattachment, the capture).   Debug output shows a whole load of QOS (quality of service), obviously because it’s all too slow with debug on (set to level 3).  I see no errors setting state to Playing though.

All in all I’m a little confused about how to do this.  If anyone has any advice I would really appreciate it.

Here’s a kind-of overview of my pipeline:

-> (pipeline)

UDPSource,
Queue,
RTPDepay,
Mpeg4Decoder,
VideoRate,
Tee

-> (bin 1, off Tee)

Queue,                     
ColourSpaceConvert,
DirectDrawSink

-> (bin 2, off Tee)

Queue,
ColourSpaceConvert,
VideoRate,
CapsFilter,
ColourSpace2,
PNGEnc,
MultiFileSink


Thanks.


Robin
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20120416/aad6fa2b/attachment.htm>


More information about the gstreamer-devel mailing list