[FFmpeg-soc] [soc]: r656 - matroska/matroskaenc.c

Aurelien Jacobs aurel at gnuage.org
Fri Aug 10 03:27:08 CEST 2007


On Fri, 10 Aug 2007 01:37:12 +0200 (CEST)
conrad <subversion at mplayerhq.hu> wrote:

> Author: conrad
> Date: Fri Aug 10 01:37:12 2007
> New Revision: 656
> 
> Log:
> Write the display size elements
> 
> 
> Modified:
>    matroska/matroskaenc.c
> 
> Modified: matroska/matroskaenc.c
> ==============================================================================
> --- matroska/matroskaenc.c	(original)
> +++ matroska/matroskaenc.c	Fri Aug 10 01:37:12 2007
> @@ -476,7 +476,10 @@ static int mkv_write_tracks(AVFormatCont
>                  // XXX: interlace flag?
>                  put_ebml_uint (pb, MATROSKA_ID_VIDEOPIXELWIDTH , codec->width);
>                  put_ebml_uint (pb, MATROSKA_ID_VIDEOPIXELHEIGHT, codec->height);
> -                // XXX: display width/height
> +                if (codec->sample_aspect_ratio.num) {
> +                    put_ebml_uint(pb, MATROSKA_ID_VIDEODISPLAYWIDTH , codec->sample_aspect_ratio.num);
> +                    put_ebml_uint(pb, MATROSKA_ID_VIDEODISPLAYHEIGHT, codec->sample_aspect_ratio.den);

I'm not sure, but I suppose that sample_aspect_ratio is something
different than videodisplaywidth/height.
I guess that you could have sample_aspect_ratio = 4/3 when
videodisplaywidth/height = 640/480.
Anyone can confirm?

Aurel



More information about the FFmpeg-soc mailing list