On Mon, Aug 11, 2014 at 10:06:10PM +0000, Christophe Gisquet wrote: > The packet buffer allocation considered as dct-coded, while it is > actually run-coded and thus requires a larger buffer. > --- > libavcodec/proresenc_kostya.c | 13 ++++++++++--- > 1 file changed, 10 insertions(+), 3 deletions(-) > > diff --git a/libavcodec/proresenc_kostya.c b/libavcodec/proresenc_kostya.c > index 2cd33ce..443ea76 100644 > --- a/libavcodec/proresenc_kostya.c > +++ b/libavcodec/proresenc_kostya.c > @@ -1232,16 +1232,23 @@ static av_cold int encode_init(AVCodecContext *avctx) > ctx->bits_per_mb = ls * 8; > if (ctx->chroma_factor == CFACTOR_Y444) > ctx->bits_per_mb += ls * 4; > - if (ctx->num_planes == 4) > - ctx->bits_per_mb += ls * 4; > } > > ctx->frame_size_upper_bound = ctx->pictures_per_frame * > ctx->slices_per_picture *
> - (2 + 2 * ctx->num_planes + > + (2 + 2 * FFMIN(3, ctx->num_planes) + slice_hdr_size is 2 + 2 * (ctx->num_planes - 1); is this difference intended ? also ctx->num_planes is currently either 3 or 4 which would make the FFMIN a constant [...] -- Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB Its not that you shouldnt use gotos but rather that you should write readable code and code with gotos often but not always is less readable
signature.asc
Description: Digital signature
_______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-devel