mån 2019-08-05 klockan 10:39 +0200 skrev Paul B Mahol: > Hi, > > Patch attached.
> +static av_cold int msrle_encode_init(AVCodecContext *avctx) > +{ > + MsrleEncContext *s = avctx->priv_data; > + > + if (av_image_check_size(avctx->width, avctx->height, 0, avctx) < 0) > + return AVERROR(EINVAL); Maybe this check should be further up in lavc? It's done for quite a few codecs. Doesn't need to hold this patch up tho > + if (avctx->gop_size == 0 || (avctx->frame_number % avctx->gop_size) == > 0) { > + /* I-Frame */ > + s->key_frame = 1; > + } else { > + /* P-Frame */ > + s->key_frame = 0; > + } Explicitly comparing I vs P would yield a better encoder Patch looks OK enough, but that's mostly based on the quick glance I gave the msrle spec on Mike's site /Tomas _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".