Commit Graph

17 Commits

Author SHA1 Message Date
Marton Balint c38f785be4 avformat/mov_chan: add support for omitted_channel bitmask in chnl atom
Signed-off-by: Marton Balint <cus@passwd.hu>
2024-04-09 23:14:22 +02:00
Marton Balint 92e7a9a4d5 avformat/mov_chan: respect channel order when parsing and creating chnl atom
Previously we always assumed that the channels are in native order, even if
they were not. The new channel layout API allows us to signal the proper
channel order, so let's do so.

Signed-off-by: Marton Balint <cus@passwd.hu>
2024-04-09 23:14:22 +02:00
Marton Balint b81ed729ec avformat/mov_chan: rework ff_mov_read_chnl
A lot of changes and fixes to channel layout parsing, notably
- get rid of dynamic allocation of channel positions
- signal unimplemented speaker positions as unknown instead of failure, but
  warn the user about it
- native order, and that a single channel only appears once was always assumed
  for less than 64 channels, obviously this was incorrect

Signed-off-by: Marton Balint <cus@passwd.hu>
2024-02-18 10:54:24 +01:00
Marton Balint f8f2142d61 avformat/mov: factorize reading the main part of the chnl atom to mov_chan
Signed-off-by: Marton Balint <cus@passwd.hu>
2024-02-18 10:54:24 +01:00
Zhao Zhili d7e864366b avformat/mov: parse ISO-14496-12 ChannelLayout
Only support chnl version 0 now.

Signed-off-by: Zhao Zhili <zhilizhao@tencent.com>
2023-03-15 00:12:59 +08:00
James Almer feb3b44c1c avformat/mov_chan: move the definition of MovChannelLayoutTag to the header
Signed-off-by: James Almer <jamrial@gmail.com>
2022-04-05 09:19:59 -03:00
James Almer c2c5f34843 avformat/movenc: write channel descriptions when a known layout or a bitmap can't be used
Fixes part of ticket #2865

Signed-off-by: James Almer <jamrial@gmail.com>
2022-04-05 09:19:59 -03:00
Vittorio Giovara b828c3954e mov: convert to new channel layout API
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: James Almer <jamrial@gmail.com>
2022-03-15 09:42:34 -03:00
Andreas Rheinhardt 49916dafb9 avformat/mov_chan: Make ff_mov_get_channel_layout() static
Possible since 3bab7cd128.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
2021-09-08 22:59:14 +02:00
Anton Khirnov c9642265f8 lavf/mov_chan: avoid avcodec.h dependency 2021-06-10 16:51:44 +02:00
Thilo Borgmann d814a839ac Reinstate proper FFmpeg license for all files. 2013-08-30 15:47:38 +00:00
Samuel Pitoiset 9afb7061f9 mov_chan: Pass a separate AVIOContext for reading
This fixes crashes when called from rtpdec_qt, where
AVFormatContext->pb is null, a crash present since 3bab7cd128.

Signed-off-by: Martin Storsjö <martin@martin.st>
2012-09-07 10:49:35 +03:00
Anton Khirnov 36ef5369ee Replace all CODEC_ID_* with AV_CODEC_ID_* 2012-08-07 16:00:24 +02:00
Justin Ruggles 3bab7cd128 avformat: move 'chan' tag parsing to mov_chan.c to share with the CAF demuxer 2012-07-19 13:26:45 -04:00
Diego Biurrun cfac648e6a doxygen: Remove documentation for non-existing parameters; misc small fixes. 2012-02-28 20:48:43 +01:00
Alex Converse 4274e481c0 mov: Support MOV_CH_LAYOUT_USE_DESCRIPTIONS for labeled descriptions. 2012-01-05 10:34:06 -08:00
Justin Ruggles 1fdf18f4b7 mov: add support for reading and writing the 'chan' tag
This implements reading the tag in the demuxer and adds support for writing it
in the muxer. Some example channel layout tables for muxing are included for
ac3, aac, and alac, but they are not utilized yet.
2011-12-09 16:12:58 -05:00