[vlc-devel] [PATCH] pgs subtitles: use origial frame size (fix #6324)

Arne de Bruijn mail at arnedebruijn.nl
Tue May 20 14:43:47 CEST 2014


On Sun, May 18, 2014 at 11:41 PM, Jean-Baptiste Kempf <jb at videolan.org> wrote:
> On 18 May, Arne de Bruijn wrote :
> > with CODEC_ID_HDMV_PGS_SUBTITLE use codec_{width,height} for
> > i_original_picture_{width,height}
> but why the difference for CODEC_ID_HDMV_PGS_SUBTITLE? Is it an upstream problem or?

I added the codec check to be on the safe side, in other cases it
probably already works ok.

I've now looked into it a bit further and usually the width/height
seems to come from the container instead of the codec. The xsub format
(that's also referenced in subtitles.c) doesn't contain a
width/height. In that case the coded_width and coded_height fields are
0. So it would probably also work to change the check to coded_width
!= 0 && coded_height != 0.

I saw you've committed my patch, thanks!



More information about the vlc-devel mailing list