Remove compatibility things

Possible with bumped FFmpeg/Libav.

These are just the simple cases.
This commit is contained in:
wm4
2016-12-07 19:44:29 +01:00
parent a660e15c9b
commit 3eceac2eab
22 changed files with 10 additions and 278 deletions

View File

@@ -133,7 +133,6 @@ static bool write_lavc(struct image_writer_ctx *ctx, mp_image_t *image, FILE *fp
pic->color_trc = mp_csp_trc_to_avcol_trc(image->params.color.gamma);
}
#if HAVE_AVCODEC_NEW_CODEC_API
int ret = avcodec_send_frame(avctx, pic);
if (ret < 0)
goto error_exit;
@@ -142,11 +141,6 @@ static bool write_lavc(struct image_writer_ctx *ctx, mp_image_t *image, FILE *fp
if (ret < 0)
goto error_exit;
got_output = 1;
#else
int ret = avcodec_encode_video2(avctx, &pkt, pic, &got_output);
if (ret < 0)
goto error_exit;
#endif
fwrite(pkt.data, pkt.size, 1, fp);