How to scale to maximum video sink width and height

Pander pander at users.sourceforge.net
Sun Oct 2 09:36:41 UTC 2016


Hi all,

For live streaming to the local screen, I am using the command:

    gst-launch-1.0 v4l2src ! autovideosink

which works fine but does not scale the output of an USB camera to the
maximum screen width and height. I can set that manually with something
such as:

    gst-launch-1.0 4l2src ! videoscale !
video/x-raw,width=1920,height=1080 ! autovideosink

but for some systems, I might need:

    gst-launch-1.0 v4l2src ! videoscale !
video/x-raw,width=1024,height=768 ! autovideosink

Now, these systems do not provide available screen dimension via xrandr
or xpdyinfo as X is not used nor is X configured.

1) Can gstreamer query the screen width and height?

2) Can a pipeline like above do that automatically with a scaling with
only referring to "maximum available screen size" in the video sink?

3) Are there other non-gstreamer tools to figure out the width and
height of a connected screen, without using tools from X?

Thanks,

Pander


More information about the gstreamer-devel mailing list