[gst-devel] How to create a IPLImage

Kulecz, Walter (JSC-SK)[WYLE INTEG. SCI. & ENG.] walter.kulecz-1 at nasa.gov
Fri Apr 9 14:39:40 CEST 2010


I'm still a novice with gstreamer, but it sounds like you are basically looking for the same input I want.  If you can modify the pipeline you have by adding a tee element to split the stream, you could send one of the tee outputs to the remainder of your pipeline, and use appsink to get at the data stream in the duplicated tee output.

As far as I can tell, the only way to learn about appsink is to download the source gst-plugins-base package and play with the code in tests/examples/app/appsink-scr.c

________________________________________
From: Carlos Castro [carloscastro7 at gmail.com]
Sent: Friday, April 09, 2010 7:12 AM
To: Discussion of the development of GStreamer
Subject: Re: [gst-devel] How to create a IPLImage

Hi Lubiao,

Thank you for your reply. I didn't know about the MultiFileSink, but I
think I can work with that.
But what I would really like, is to access the buffers that hold the
current frame data:

gst-launch videotestsrc num-buffers=100 ! \
  video/x-raw-yuv,format=\(I420\),width=320,height=240 ! \
  multifilesink

( I'm working in C language using the gstreamer0.10 API.)
In this example, if I translate the pipeline to implement in my C
code, how can I access this buffers? I don't know how to link them in
the pipeline, so I can use them.

Thanks,
Carlos Castro

2010/4/9 lubiao <lubiao.py at gmail.com>:
> On Fri, Apr 9, 2010 at 4:30 PM, Carlos Castro <carloscastro7 at gmail.com> wrote:
>> Hi everyone,
>>
>> I'm trying to get a snapshot from a webcam that is continuously
>> sending the picture to a GTK+ app using a gtreamer pipeline, so I can
>> save that snapshot as a IPLImage, to later use it with OpenCV.
>>
>> I searched the web to find the answer and I found that I could use a
>> gstbuffer to store the frame that gstreamer grabs from the v4l2src,
>> but I couldn't get it to work...  How do I get the data from the
>> pipeline to the buffer?
>>
>> Thanks,
>> Carlos Castro
>>
> snapshot  example
>
> gst-launch uridecodebin uri=file:///path/to/some/file ! \
>  ffmpegcolorspace ! videoscale !
>  pngenc snapshot=false ! multifilesink location=output-%05d.png
>
> http://www.gstreamer.net/wiki/MultiFileSink
>
> ------------------------------------------------------------------------------
> 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
>



--
Cumprimentos,
Carlos Castro

------------------------------------------------------------------------------
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



More information about the gstreamer-devel mailing list