diff options
author | Nicolas George <nicolas.george@normalesup.org> | 2013-01-01 20:06:04 +0400 |
---|---|---|
committer | Nicolas George <nicolas.george@normalesup.org> | 2013-01-01 23:07:37 +0400 |
commit | 5ed5e90f2ae299cbec66996860d794771a85fee8 (patch) | |
tree | 42dbfc175bee04454d14efe83b804f113be6fbc6 /libavcodec/pgssubdec.c | |
parent | 8dbbaf568ed9b9c76af596fc7daecbe1b971a7ce (diff) |
lavc/dvdsubenc: improve color distance function.
Consider the color space as an hypercone with apex alpha=0
and base alpha=1 instead of an hypercube.
Make the encoder consider very transparent colors more similar
even if the hue is very different.
This corresponds roughly to using the alpha as a weight for the
color difference.
Only 4 bits of alpha are used, because this is what dvdsub uses,
and it avoids overflows.
Fix trac ticket #2005.
Diffstat (limited to 'libavcodec/pgssubdec.c')
0 files changed, 0 insertions, 0 deletions