Commit graph

10 commits

Author SHA1 Message Date
Andreas Rheinhardt
188440929d avcodec/libmpeghdec: Check channel layouts generically
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:38:46 +02:00
Andreas Rheinhardt
ca7679c82f avcodec/libmpeghdec: Don't set AVCodecContext.frame_size
It indicates a constant frame size (in samples); yet the documentation
of the MPEGH_DECODER_OUTPUT_INFO structure says that it
"gives information about the currently decoded audio data"
and makes no guarantees about it being constant.

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:38:41 +02:00
Andreas Rheinhardt
7cd0641a99 avcodec/libmpeghdec: Align FFCodec initializers
Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:38:37 +02:00
Andreas Rheinhardt
0ec21ea8d0 avcodec/libmpeghdec: Remove always-false check
The pointer to the decoder is always set after init has been
called successfully.

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:38:32 +02:00
Andreas Rheinhardt
f46bd4add2 avcodec/libmpeghdec: Don't use too big buffer
The channel count is fixed, so we don't need to allocate
space to hold samples for nonexisting channels. This also
means that the maximum channel count is no longer hardcoded
in the macro.
Also switch to decoder_buffer_size to be samples-based.

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:37:55 +02:00
Andreas Rheinhardt
60b88e75e4 avcodec/libmpeghdec: Inline constant
Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:37:51 +02:00
Andreas Rheinhardt
a98f75d22c avcodec/libmpeghdec: Don't set AVCodec.sample_fmts
It is mostly pointless for decoders (only useful for those
codecs for which a floating-point and a fixed-point decoder
exist).

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:37:30 +02:00
Andreas Rheinhardt
839042b0c0 avcodec/libmpeghdec: Remove private class
This decoder doesn't have any options.

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:37:24 +02:00
Andreas Rheinhardt
b8f341ff05 avcodec/libmpeghdec: Remove redundant manual close calls
This decoder has the INIT_CLEANUP flag set.

Reviewed-by: Lynne <dev@lynne.ee>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2025-09-26 05:36:42 +02:00
Stadelmann, Daniel
56c14f2311 avcodec/libmpeghdec: add MPEG-H 3DA Fraunhofer IIS mpeghdec decoder
Adds a wrapper around the Fraunhofer IIS MPEG-H 3D Audio mpeghdec [1]
decoder shared library.

[1] https://github.com/Fraunhofer-IIS/mpeghdec

Signed-off-by: Stadelmann, Daniel <daniel.stadelmann@iis.fraunhofer.de>
2025-09-24 08:25:42 +02:00