[MPlayer-dev-eng] [PATCH] ae_lavc: set nBlockAlign like libavformat

Nicolas George nicolas.george at normalesup.org
Sat Aug 27 20:12:26 CEST 2011


Le decadi 10 fructidor, an CCXIX, Reimar Döffinger a écrit :
> frame_size is currently passed vide dwScale.
> That is quite broken and causes issues, but adding another
> hack/breakages is not really the right way to go.

I do not think this is broken. As far as I understand the spec,
dwScale/dwRate is what, in sane formats, is called the time_base. Therefore,
setting dwScale=frame_size and dwRate=sample_rate is correct. That is what
lavf does too, except it reduces the fraction.

As for nBlockAlign, the comments in the code seem to indicate it is a matter
of matching bug-for-bug the behaviour of the muxer/demuxers from microsoft.

All I can say is that mencoder currently produces a file that mplayer and
ffmpeg both recognize as completely broken, and that this patch fixes it by
doing exactly the same thing as lavf.

> Also demux_lavf should need exactly the same change or stream
> copy would still not work.

Stream copy seems indeed currently broken with demux_lavf. The reason may be
similar, but that does not mean the fix for the first problem can not be
applied before the fix for the second is found.

Regards,

-- 
  Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20110827/5c6f293e/attachment.asc>


More information about the MPlayer-dev-eng mailing list