diff options
author | JULIAN GARDNER <joolzg@btinternet.com> | 2017-10-24 22:46:00 +0200 |
---|---|---|
committer | Carl Eugen Hoyos <ceffmpeg@gmail.com> | 2017-10-24 22:46:00 +0200 |
commit | df95f145be1556da7e147d642e4fd8bf96276321 (patch) | |
tree | 404b98180cba88cdc340e104b92a6c6ca2d607a6 | |
parent | 3c14547eb75c5b18099060085d12f09518ee2732 (diff) |
lavc/dvbsub: Do not fail hard in the region block for 256-colour encoding.
Adds a hunk forgotten in 8a6799d2
-rw-r--r-- | libavcodec/dvbsub.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/libavcodec/dvbsub.c b/libavcodec/dvbsub.c index 3cdbade99c..04c0c60626 100644 --- a/libavcodec/dvbsub.c +++ b/libavcodec/dvbsub.c @@ -342,6 +342,9 @@ static int encode_dvb_subtitles(DVBSubtitleContext *s, } else if (h->rects[region_id]->nb_colors <= 16) { /* 4 bpp, standard encoding */ bpp_index = 1; + } else if (h->rects[region_id]->nb_colors <= 256) { + /* 8 bpp, standard encoding */ + bpp_index = 2; } else { return -1; } |