On Tue, May 19, 2015 at 04:57:46PM +0100, Vittorio Giovara wrote: > Some clients incorrectly set 24 as bits_per_coded_sample, while > the actual value is preseved in one of the headers.
prese_R_ved "present in one of the file headers" is probably more accurate. > --- a/libavcodec/vmnc.c > +++ b/libavcodec/vmnc.c > @@ -419,10 +419,18 @@ static int decode_frame(AVCodecContext *avctx, void > *data, int *got_frame, > + > + /* reset values */ > + c->bpp = depth; > + c->bpp2 = c->bpp / 8; align = > @@ -524,6 +532,9 @@ static av_cold int decode_init(AVCodecContext *avctx) > case 16: > avctx->pix_fmt = AV_PIX_FMT_RGB555; > break; > + case 24: > + /* 24 bits is not technically supported, but some clients might > + * mistakenly set it -- delay the actual check in decode_frame() */ This expresses the opposite of what you seem to have in mind. It should be "until decode_frame()" instead of "in decode_frame()", like you said in the log message. probably OK Diego _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel