diff options
author | Akihiro Tsukada <atsukada@users.sourceforge.net> | 2012-08-25 20:30:54 +0900 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-09-15 03:50:04 +0200 |
commit | c3c646a868b46f60c2761c9fc8295438868a5df2 (patch) | |
tree | 48f56f462e7c7235c4bb5777f5184ceeaf2c0f61 /libavcodec/avcodec.h | |
parent | 75d34864d16fbf02928c319134bd94a7a7752092 (diff) | |
download | ffmpeg-c3c646a868b46f60c2761c9fc8295438868a5df2.tar.gz |
aacdec: add support for dual mono in Japanese DTV
Japanese DTV uses some non standard extensions in AAC audio.
One example is 'dual mono', which combines two independent
audio into one stereo stream, storing them in left and right channels
respectively. Historically, dual mono audio has been used for
multi-lingual audio, one for local/native language, and another for english,
and usually the "main" (local language) channel should be output without
any user interactions.
The frames of those dual mono audio are allowed to set
ADTS channel_config field to 0, and just contain two SCE's *WITHOUT* PCE,
which is a non standard extension by Japanese DTV standard.
(ref. ARIB STD-B32 PartII 5.2.3)
This patch adds an AVPacket side data, AV_PKT_DATA_JP_DUALMONO,
which indicates that the AVPacket is likely to contain an audio frame
with the above dual mono extension, and has the parameter to specify
the desired channel selection in that case.
It also makes aacdec to detect dual mono and output just the desired
channel when this side data is attached.
Signed-off-by: Akihiro Tsukada <atsukada@users.sourceforge.net>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/avcodec.h')
-rw-r--r-- | libavcodec/avcodec.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libavcodec/avcodec.h b/libavcodec/avcodec.h index ddf785e68a..8e3eaecd16 100644 --- a/libavcodec/avcodec.h +++ b/libavcodec/avcodec.h @@ -927,6 +927,16 @@ enum AVPacketSideDataType { * @endcode */ AV_PKT_DATA_SKIP_SAMPLES=70, + + /** + * An AV_PKT_DATA_JP_DUALMONO side data packet indicates that + * the packet may contain "dual mono" audio specific to Japanese DTV + * and if it is true, recommends only the selected channel to be used. + * @code + * u8 selected channels (0=mail/left, 1=sub/right, 2=both) + * @endcode + */ + AV_PKT_DATA_JP_DUALMONO, }; typedef struct AVPacket { |