| Top |
| gchar * | data | Write |
| gboolean | fit-to-frame | Read / Write |
| gchar * | location | Write |
| gint | x | Read / Write |
| gint | y | Read / Write |
| gint | height | Read / Write |
| gfloat | height-relative | Read / Write |
| gint | width | Read / Write |
| gfloat | width-relative | Read / Write |
| gfloat | x-relative | Read / Write |
| gfloat | y-relative | Read / Write |
GObject
╰── GstObject
╰── GstElement
╰── GstBaseTransform
╰── GstVideoFilter
╰── GstRsvgOverlay
This elements overlays SVG graphics over the video. SVG data can either be specified through properties, or fed through the data-sink pad.
Position and dimension of the SVG graphics can be achieved by specifying appropriate dimensions in the SVG file itself, but shortcuts are provided by the element to specify x/y position and width/height dimension, both in absolute form (pixels) and in relative form (percentage of video dimension).
For any measure (x/y/width/height), the absolute value (in pixels) takes precedence over the relative one if both are specified. Absolute values must be set to 0 to disable them.
If all parameters are 0, the image is displayed without rescaling at (0, 0) position.
The fit-to-frame property is a shortcut for displaying the SVG overlay at (0, 0) position filling the whole screen. It modifies the values of the x/y/width/height attributes, by setting height-/width-relative to 1.0. and all other attributes to 0.
1 |
gst-launch -v videotestsrc ! ffmpegcolorspace ! rsvgoverlay location=foo.svg ! ffmpegcolorspace ! autovideosink |
1 |
gst-launch -v videotestsrc ! ffmpegcolorspace ! rsvgoverlay name=overlay ! ffmpegcolorspace ! autovideosink filesrc location=foo.svg ! image/svg ! overlay.data_sink |
1 |
gst-launch -v videotestsrc ! ffmpegcolorspace ! rsvgoverlay data='<svg viewBox="0 0 800 600"><image x="80%" y="80%" width="10%" height="10%" xlink:href="foo.jpg" /></svg>' ! ffmpegcolorspace ! autovideosink |
“fit-to-frame” property “fit-to-frame” gboolean
Fit the SVG to fill the whole frame.
Owner: GstRsvgOverlay
Flags: Read / Write
Default value: TRUE
“location” property “location” gchar *
SVG file location.
Owner: GstRsvgOverlay
Flags: Write
Default value: ""
“x” property “x” gint
Specify an x offset.
Owner: GstRsvgOverlay
Flags: Read / Write
Allowed values: >= -2147483647
Default value: 0
“y” property “y” gint
Specify a y offset.
Owner: GstRsvgOverlay
Flags: Read / Write
Allowed values: >= -2147483647
Default value: 0
“height” property “height” gint
Specify a height in pixels.
Owner: GstRsvgOverlay
Flags: Read / Write
Allowed values: >= -2147483647
Default value: 0
“height-relative” property “height-relative” gfloat
Specify a height relative to the display size.
Owner: GstRsvgOverlay
Flags: Read / Write
Default value: 0
“width” property “width” gint
Specify a width in pixels.
Owner: GstRsvgOverlay
Flags: Read / Write
Allowed values: >= -2147483647
Default value: 0
“width-relative” property “width-relative” gfloat
Specify a width relative to the display size.
Owner: GstRsvgOverlay
Flags: Read / Write
Default value: 0
“x-relative” property “x-relative” gfloat
Specify an x offset relative to the display size.
Owner: GstRsvgOverlay
Flags: Read / Write
Default value: 0