diff options
author | wm4 <wm4@nowhere> | 2016-12-07 19:44:29 +0100 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2016-12-07 19:53:11 +0100 |
commit | 3eceac2eab0b42ee082a0b615ebf40a21f0fb915 (patch) | |
tree | a7f719897b49f44006d44a1efcdab3b8d203aad8 /video/out/vo_lavc.c | |
parent | a660e15c9b96bd46209e78b3c3d4cf136a039a50 (diff) | |
download | mpv-3eceac2eab0b42ee082a0b615ebf40a21f0fb915.tar.bz2 mpv-3eceac2eab0b42ee082a0b615ebf40a21f0fb915.tar.xz |
Remove compatibility things
Possible with bumped FFmpeg/Libav.
These are just the simple cases.
Diffstat (limited to 'video/out/vo_lavc.c')
-rw-r--r-- | video/out/vo_lavc.c | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/video/out/vo_lavc.c b/video/out/vo_lavc.c index 1721136f8b..5c7406d4b9 100644 --- a/video/out/vo_lavc.c +++ b/video/out/vo_lavc.c @@ -241,7 +241,6 @@ static void encode_video_and_write(struct vo *vo, AVFrame *frame) struct priv *vc = vo->priv; AVPacket packet = {0}; -#if HAVE_AVCODEC_NEW_CODEC_API int status = avcodec_send_frame(vc->codec, frame); if (status < 0) { MP_ERR(vo, "error encoding at %d %d/%d\n", @@ -276,24 +275,6 @@ static void encode_video_and_write(struct vo *vo, AVFrame *frame) write_packet(vo, &packet); av_packet_unref(&packet); } -#else - av_init_packet(&packet); - int got_packet = 0; - int status = avcodec_encode_video2(vc->codec, &packet, frame, &got_packet); - if (status < 0) { - MP_ERR(vo, "error encoding at %d %d/%d\n", - frame ? (int) frame->pts : -1, - vc->codec->time_base.num, - vc->codec->time_base.den); - return; - } - if (!got_packet) { - return; - } - encode_lavc_write_stats(vo->encode_lavc_ctx, vc->codec); - write_packet(vo, &packet); - av_packet_unref(&packet); -#endif } static void draw_image_unlocked(struct vo *vo, mp_image_t *mpi) |