[gst-devel] How do I get the size of a video?

Bastian Winkler buz at netbuz.org
Tue Mar 18 13:25:41 CET 2008


hello daniel,

you can connect to the 'notify::caps' signal on the videoscale's sink
pad and query for the negotiated caps via gst_pad_get_negotiated_caps
there you'll get width, height and pixel-aspect-ratio of the video.

:wq buz

On Tue, Mar 18, 2008 at 04:58:49AM -0700, danielkun at iremo.com wrote:
> 
> Hello,
> 
> Videoscale doesn't scale the MPEG files correctly so I'd like to set the
> ratio manually.
> (480x480, 4:3 videos are displayed at 1:1. 352x480, 4:3 are displayed as
> 3:4...)
> 
> My pipeline looks like this:
> (filesrc, mpegdemux, queue, mpeg2dec, videoscale, capsfilter,
> ffmpegcolorspace, dfbvideosink)
> 
> How would I be able to get the ratio (size) of the video?
> 
> Thank you,
> 
> Daniel
> 
> 
> -------------------------------------------------------------------------
> This SF.net email is sponsored by: Microsoft
> Defy all challenges. Microsoft(R) Visual Studio 2008.
> http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel

-- 
/* Nobody will ever see this message :-) */
panic("Cannot initialize video hardware\n");
        2.0.38 /usr/src/linux/arch/m68k/atari/atafb.c

GnuPG Fingerprint: 2FFF FC48 C7DF 1EA0 00A0  FD53 8C35 FD2E 6908 7B82
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20080318/f79b139d/attachment.pgp>


More information about the gstreamer-devel mailing list