diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-05-08 12:33:09 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2020-05-08 20:55:49 +0200 |
commit | 6db97188d89e70d389e102a6f72555cfee64af30 (patch) | |
tree | 1fb80d8a1d9c4e9615708ab402a98c12f8dd3222 | |
parent | 47cd3c88c5f3180710494b775634398be1445fbf (diff) | |
download | ffmpeg-6db97188d89e70d389e102a6f72555cfee64af30.tar.gz |
avcodec/(null|opus_metadata)_bsf: Use ff_bsf_get_packet_ref() directly
Reviewed-by: James Almer <jamrial@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
-rw-r--r-- | libavcodec/null_bsf.c | 7 | ||||
-rw-r--r-- | libavcodec/opus_metadata_bsf.c | 7 |
2 files changed, 2 insertions, 12 deletions
diff --git a/libavcodec/null_bsf.c b/libavcodec/null_bsf.c index 24d26dfb1a..37f4640c87 100644 --- a/libavcodec/null_bsf.c +++ b/libavcodec/null_bsf.c @@ -24,12 +24,7 @@ #include "avcodec.h" #include "bsf.h" -static int null_filter(AVBSFContext *ctx, AVPacket *pkt) -{ - return ff_bsf_get_packet_ref(ctx, pkt); -} - const AVBitStreamFilter ff_null_bsf = { .name = "null", - .filter = null_filter, + .filter = ff_bsf_get_packet_ref, }; diff --git a/libavcodec/opus_metadata_bsf.c b/libavcodec/opus_metadata_bsf.c index 867ad830d3..d22db54f30 100644 --- a/libavcodec/opus_metadata_bsf.c +++ b/libavcodec/opus_metadata_bsf.c @@ -25,11 +25,6 @@ typedef struct OpusBSFContext { int gain; } OpusBSFContext; -static int opus_metadata_filter(AVBSFContext *bsfc, AVPacket *pkt) -{ - return ff_bsf_get_packet_ref(bsfc, pkt); -} - static int opus_metadata_init(AVBSFContext *bsfc) { OpusBSFContext *s = bsfc->priv_data; @@ -67,6 +62,6 @@ const AVBitStreamFilter ff_opus_metadata_bsf = { .priv_data_size = sizeof(OpusBSFContext), .priv_class = &opus_metadata_class, .init = &opus_metadata_init, - .filter = &opus_metadata_filter, + .filter = &ff_bsf_get_packet_ref, .codec_ids = codec_ids, }; |