[FFmpeg-cvslog] avcodec/ffv1enc: fix assertion failure with unset bits per raw sample

Michael Niedermayer git at videolan.org
Mon Jul 20 02:22:48 CEST 2015


ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Mon Jul 20 02:10:04 2015 +0200| [749f85496ccff345ec811976ce45ec9e1900e9a8] | committer: Michael Niedermayer

avcodec/ffv1enc: fix assertion failure with unset bits per raw sample

Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=749f85496ccff345ec811976ce45ec9e1900e9a8
---

 libavcodec/ffv1enc.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/libavcodec/ffv1enc.c b/libavcodec/ffv1enc.c
index 45ab3a3..a47a64d 100644
--- a/libavcodec/ffv1enc.c
+++ b/libavcodec/ffv1enc.c
@@ -755,6 +755,8 @@ static av_cold int encode_init(AVCodecContext *avctx)
         s->transparency = desc->nb_components == 4;
         if (!avctx->bits_per_raw_sample && !s->bits_per_raw_sample)
             s->bits_per_raw_sample = 8;
+        else if (!s->bits_per_raw_sample)
+            s->bits_per_raw_sample = 8;
         break;
     case AV_PIX_FMT_RGB32:
         s->colorspace = 1;



More information about the ffmpeg-cvslog mailing list