Quoting Mark Thompson (2016-09-06 22:53:18) > @@ -2480,6 +2514,20 @@ int vp78_decode_frame(AVCodecContext *avctx, void > *data, int *got_frame, > if (ret < 0) > goto err; > > + if (!is_vp7 && s->pix_fmt == AV_PIX_FMT_NONE) { > + enum AVPixelFormat pix_fmts[] = { > + AV_PIX_FMT_YUV420P, > + AV_PIX_FMT_NONE, > + }; > + > + s->pix_fmt = ff_get_format(s->avctx, pix_fmts); > + if (s->pix_fmt < 0) { > + ret = AVERROR_BUG;
AVERROR_BUG is meant to be used in cases that should not happen in valid code, it's like a "soft assert". Since it's perfectly valid for ff_get_format() to fail, you should instead use something like AVERROR_UNKNOWN. The rest of the set looks fine to me, feel free to push with the above change. -- Anton Khirnov _______________________________________________ libav-devel mailing list libav-devel@libav.org https://lists.libav.org/mailman/listinfo/libav-devel