aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mmaldec.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-12-09 12:58:02 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-12-12 16:56:04 +0100
commit7fe5c7f02dbcda8494150ca79922e4994399274b (patch)
tree544380d7d6daa660ce9af9f18efcebbb80a9180b /libavcodec/mmaldec.c
parent9644ee224f56118e5b1ac4edc1b088a6a6ac2ac7 (diff)
downloadffmpeg-7fe5c7f02dbcda8494150ca79922e4994399274b.tar.gz
avcodec/mmaldec: Deduplicate AVClasses
Possible now that the child_class_next API is gone. Tested-by: Cameron Gutman <aicommander@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/mmaldec.c')
-rw-r--r--libavcodec/mmaldec.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/libavcodec/mmaldec.c b/libavcodec/mmaldec.c
index 0a1905b3a0..cd645189d9 100644
--- a/libavcodec/mmaldec.c
+++ b/libavcodec/mmaldec.c
@@ -820,16 +820,14 @@ static const AVOption options[]={
{NULL}
};
-#define FFMMAL_DEC_CLASS(NAME) \
- static const AVClass ffmmal_##NAME##_dec_class = { \
- .class_name = "mmal_" #NAME "_dec", \
- .item_name = av_default_item_name, \
- .option = options, \
- .version = LIBAVUTIL_VERSION_INT, \
- };
+static const AVClass ffmmal_dec_class = {
+ .class_name = "mmal_dec",
+ .item_name = av_default_item_name,
+ .option = options,
+ .version = LIBAVUTIL_VERSION_INT,
+};
#define FFMMAL_DEC(NAME, ID) \
- FFMMAL_DEC_CLASS(NAME) \
const AVCodec ff_##NAME##_mmal_decoder = { \
.name = #NAME "_mmal", \
.long_name = NULL_IF_CONFIG_SMALL(#NAME " (mmal)"), \
@@ -840,7 +838,7 @@ static const AVOption options[]={
.close = ffmmal_close_decoder, \
.receive_frame = ffmmal_receive_frame, \
.flush = ffmmal_flush, \
- .priv_class = &ffmmal_##NAME##_dec_class, \
+ .priv_class = &ffmmal_dec_class, \
.capabilities = AV_CODEC_CAP_DELAY | AV_CODEC_CAP_HARDWARE, \
.caps_internal = FF_CODEC_CAP_SETS_PKT_DTS, \
.pix_fmts = (const enum AVPixelFormat[]) { AV_PIX_FMT_MMAL, \