[FFmpeg-cvslog] dvbsubdec: don't hardcode subtitle colors count in dvbsubdec to 16
Joakim Plate
git at videolan.org
Sat Sep 10 23:33:39 CEST 2011
ffmpeg | branch: master | Joakim Plate <elupus at ecce.se> | Sat Sep 10 23:12:29 2011 +0200| [4a3294ef0069c898a495c783dfdb2f0bf1dc6583] | committer: Michael Niedermayer
dvbsubdec: don't hardcode subtitle colors count in dvbsubdec to 16
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=4a3294ef0069c898a495c783dfdb2f0bf1dc6583
---
libavcodec/dvbsubdec.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/libavcodec/dvbsubdec.c b/libavcodec/dvbsubdec.c
index 1ee7aad..ad213c8 100644
--- a/libavcodec/dvbsubdec.c
+++ b/libavcodec/dvbsubdec.c
@@ -1360,7 +1360,7 @@ static int dvbsub_display_end_segment(AVCodecContext *avctx, const uint8_t *buf,
rect->y = display->y_pos + offset_y;
rect->w = region->width;
rect->h = region->height;
- rect->nb_colors = 16;
+ rect->nb_colors = (1 << region->depth);
rect->type = SUBTITLE_BITMAP;
rect->pict.linesize[0] = region->width;
More information about the ffmpeg-cvslog
mailing list