drawing element?

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

drawing element?

Kocsis Tibor
Hi,

is there any easy way to draw something to the top of the picture? For
example a rectangle or a shape (with alpha channel?) specified by
coordinates.

I assume it is possible with a properly cropped png and videomix
element, but what's the correct way to do something like this? Any
ideas and pipelines are welcome :)

Thanks in advance
Tibor

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

Re: drawing element?

Olivier Aubert-2
On Thu, 2010-05-06 at 10:55 +0200, Kocsis Tibor wrote:
> Hi,
>
> is there any easy way to draw something to the top of the picture? For
> example a rectangle or a shape (with alpha channel?) specified by
> coordinates.
>
> I assume it is possible with a properly cropped png and videomix
> element, but what's the correct way to do something like this? Any
> ideas and pipelines are welcome :)
Correct, I do not know. But I have developed a SVG overlay plugin for
gstreamer (in python), which perfectly fits the bill (draw shapes over
the video). See http://liris.cnrs.fr/olivier.aubert/svgoverlay.py for
the code.

Olivier


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

Re: drawing element?

Stefan Sauer
In reply to this post by Kocsis Tibor
hi,

Kocsis Tibor wrote:

> Hi,
>
> is there any easy way to draw something to the top of the picture? For
> example a rectangle or a shape (with alpha channel?) specified by
> coordinates.
>
> I assume it is possible with a properly cropped png and videomix
> element, but what's the correct way to do something like this? Any
> ideas and pipelines are welcome :)
>  
On the N900 the camera uses colorkeying in the xvimagesink. That is one
can draw normally on the window and where the pixels are painted in the
colorkey color you see the video.

Stefan

> Thanks in advance
> Tibor
>
> ------------------------------------------------------------------------------
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>  


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

Re: drawing element?

Kocsis Tibor
In reply to this post by Olivier Aubert-2
Thanks Oliver, I looked into the code, it will be useful. Maybe we
will create a gstreamer element based on that.

Just for the record here is an example pipeline how to draw a
rectangle with user defined dimension on a camera live view:

gst-launch -v  multifilesrc location=bg.png ! image/png,
framerate=25/1 ! pngdec ! ffmpegcolorspace ! alpha ! videoscale !
video/x-raw-yuv,width=320, height=240 ! videobox top=-80 left=-100
border-alpha=0 alpha=0.5 ! videocrop bottom=180 right=200 ! videomixer
name=mix ! ffmpegcolorspace ! xvimagesink    rtspsrc
location="rtsp://.../axis-media/media.amp?videocodec=h264&clock=1&resolution=320x240"
! rtph264depay ! h264parse ! ffdec_h264 ! ffmpegcolorspace ! alpha !
mix.




On Thu, May 6, 2010 at 11:28 AM, Olivier Aubert
<[hidden email]> wrote:

> On Thu, 2010-05-06 at 10:55 +0200, Kocsis Tibor wrote:
>> Hi,
>>
>> is there any easy way to draw something to the top of the picture? For
>> example a rectangle or a shape (with alpha channel?) specified by
>> coordinates.
>>
>> I assume it is possible with a properly cropped png and videomix
>> element, but what's the correct way to do something like this? Any
>> ideas and pipelines are welcome :)
> Correct, I do not know. But I have developed a SVG overlay plugin for
> gstreamer (in python), which perfectly fits the bill (draw shapes over
> the video). See http://liris.cnrs.fr/olivier.aubert/svgoverlay.py for
> the code.
>
> Olivier
>
>
> ------------------------------------------------------------------------------
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>

------------------------------------------------------------------------------

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel