diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:13:14 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 01:13:14 +0000 |
commit | 5a3b54c78ce63d899f76dbb3db72e4894b40bd53 (patch) | |
tree | 50693d13eeefc4d683bdf5417f0861b0ef274a0c /video/decode/vd_lavc.c | |
parent | Adding debian version 0.37.0-1. (diff) | |
download | mpv-5a3b54c78ce63d899f76dbb3db72e4894b40bd53.tar.xz mpv-5a3b54c78ce63d899f76dbb3db72e4894b40bd53.zip |
Merging upstream version 0.38.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'video/decode/vd_lavc.c')
-rw-r--r-- | video/decode/vd_lavc.c | 17 |
1 files changed, 11 insertions, 6 deletions
diff --git a/video/decode/vd_lavc.c b/video/decode/vd_lavc.c index b971d26..05b66ed 100644 --- a/video/decode/vd_lavc.c +++ b/video/decode/vd_lavc.c @@ -1215,6 +1215,8 @@ static int decode_frame(struct mp_filter *vd) return ret; } + mp_codec_info_from_av(avctx, ctx->codec); + // If something was decoded successfully, it must return a frame with valid // data. assert(ctx->pic->buf[0]); @@ -1369,14 +1371,14 @@ static int control(struct mp_filter *vd, enum dec_ctrl cmd, void *arg) return CONTROL_UNKNOWN; } -static void process(struct mp_filter *vd) +static void vd_lavc_process(struct mp_filter *vd) { vd_ffmpeg_ctx *ctx = vd->priv; lavc_process(vd, &ctx->state, send_packet, receive_frame); } -static void reset(struct mp_filter *vd) +static void vd_lavc_reset(struct mp_filter *vd) { vd_ffmpeg_ctx *ctx = vd->priv; @@ -1386,7 +1388,7 @@ static void reset(struct mp_filter *vd) ctx->framedrop_flags = 0; } -static void destroy(struct mp_filter *vd) +static void vd_lavc_destroy(struct mp_filter *vd) { vd_ffmpeg_ctx *ctx = vd->priv; @@ -1398,9 +1400,9 @@ static void destroy(struct mp_filter *vd) static const struct mp_filter_info vd_lavc_filter = { .name = "vd_lavc", .priv_size = sizeof(vd_ffmpeg_ctx), - .process = process, - .reset = reset, - .destroy = destroy, + .process = vd_lavc_process, + .reset = vd_lavc_reset, + .destroy = vd_lavc_destroy, }; static struct mp_decoder *create(struct mp_filter *parent, @@ -1443,6 +1445,9 @@ static struct mp_decoder *create(struct mp_filter *parent, talloc_free(vd); return NULL; } + + codec->codec_desc = ctx->avctx->codec_descriptor->long_name; + return &ctx->public; } |