[FFmpeg-devel] dvdsub encoder: respect palette when it makes sense

Michael Niedermayer michaelni
Mon Mar 2 16:20:21 CET 2009

On Mon, Mar 02, 2009 at 10:32:07AM +0100, Nicolas George wrote:
> Le duodi 12 vent?se, an CCXVII, Michael Niedermayer a ?crit?:
> > dvdsubdec seems to support 8bit
> I found some information here:
> http://www.mpeg.org/MPEG/DVD/Book_B/Subpic.html
> and there:
> http://dvd.sourceforge.net/dvdinfo/spu.html
> # 4 colors out of 16 color palette (4 colors are determined once per PGC).
> # 4 out of 16 contrast values
> In practice, that means:
> - there is a 16-colors palette in the DVD title's IFO file or the VOBSUB idx
>   file;
> - each subpicture packet is a 4-color pixmap;
> - each subpicture packet has two fields that give, for the four color cells,
>   the alpha value and the palette entry number (lines 164-167 of the current
>   code).
> The 8bit stuff is for HD-DVD subtitles, added by revision 9788. The encoder
> does not support HD-DVD subtitles.
> > also in the other mail you spoke about makin them playabe in mplayer, this
> > actually is of almost no relevance, it rather matters if they ae playable
> > on hardware dvd players / if they are compliant tto he specs 
> You are perfectly right in principle, and I did not express myself
> correctly. I can make a VOBSUB file that mplayer can play with either the
> current version of my patched version; supposedly, other compliant players
> would play it too.

i do not thing the authors of the code on mplayet had access to the dvd specs.
actually iam pretty darn sure they did not.
I really think testing should happen with some player that was written by
people who saw the whole dvd specs.
That is for changing the encoder output in non trivial ways of course not
for just telling the user that the input is invalid or trivial changes ...

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

When the tyrant has disposed of foreign enemies by conquest or treaty, and
there is nothing more to fear from them, then he is always stirring up
some war or other, in order that the people may require a leader. -- Plato
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20090302/0dcef48e/attachment.pgp>

More information about the ffmpeg-devel mailing list