[FFmpeg-cvslog] Set bits_per_raw_sample when decoding pnm.

Carl Eugen Hoyos git at videolan.org
Tue Aug 6 01:08:13 CEST 2013


ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Tue Aug  6 00:26:21 2013 +0200| [4c15f3491f1991554ad497788dfb6ad02b552134] | committer: Carl Eugen Hoyos

Set bits_per_raw_sample when decoding pnm.

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

 libavcodec/pnmdec.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/pnmdec.c b/libavcodec/pnmdec.c
index df9b5ee..c7a7a44 100644
--- a/libavcodec/pnmdec.c
+++ b/libavcodec/pnmdec.c
@@ -58,6 +58,7 @@ static int pnm_decode_frame(AVCodecContext *avctx, void *data,
         return ret;
     p->pict_type = AV_PICTURE_TYPE_I;
     p->key_frame = 1;
+    avctx->bits_per_raw_sample = av_log2(s->maxval) + 1;
 
     switch (avctx->pix_fmt) {
     default:



More information about the ffmpeg-cvslog mailing list