aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorAnton Khirnov <anton@khirnov.net>2011-02-03 14:26:09 +0100
committerRonald S. Bultje <rsbultje@gmail.com>2011-02-06 08:26:12 -0500
commitc2fcd0a7a4d0bda1a3306e40b70ce281a987df60 (patch)
tree2f1d6751e938b53e2ae2734393079ef296666bbd /libavcodec
parentad3cffb68f9c77e140660a8ae7d43c8606208178 (diff)
downloadffmpeg-c2fcd0a7a4d0bda1a3306e40b70ce281a987df60.tar.gz
Replace remaining occurrences of deprecated CH_* with AV_CH_*
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/ac3_parser.c3
-rw-r--r--libavcodec/apedec.c3
-rw-r--r--libavcodec/audioconvert.h1
-rw-r--r--libavcodec/cook.c3
-rw-r--r--libavcodec/dca.c4
-rw-r--r--libavcodec/imc.c3
-rw-r--r--libavcodec/mpc7.c3
-rw-r--r--libavcodec/mpc8.c3
-rw-r--r--libavcodec/smacker.c3
-rw-r--r--libavcodec/vorbis_data.c17
-rw-r--r--libavcodec/wavpack.c3
11 files changed, 28 insertions, 18 deletions
diff --git a/libavcodec/ac3_parser.c b/libavcodec/ac3_parser.c
index 4737d6f868..bab354d6b9 100644
--- a/libavcodec/ac3_parser.c
+++ b/libavcodec/ac3_parser.c
@@ -24,6 +24,7 @@
#include "ac3_parser.h"
#include "aac_ac3_parser.h"
#include "get_bits.h"
+#include "libavcore/audioconvert.h"
#define AC3_HEADER_SIZE 7
@@ -123,7 +124,7 @@ int ff_ac3_parse_header(GetBitContext *gbc, AC3HeaderInfo *hdr)
}
hdr->channel_layout = ff_ac3_channel_layout_tab[hdr->channel_mode];
if (hdr->lfe_on)
- hdr->channel_layout |= CH_LOW_FREQUENCY;
+ hdr->channel_layout |= AV_CH_LOW_FREQUENCY;
return 0;
}
diff --git a/libavcodec/apedec.c b/libavcodec/apedec.c
index b6d6f9d9cc..e673b88bee 100644
--- a/libavcodec/apedec.c
+++ b/libavcodec/apedec.c
@@ -25,6 +25,7 @@
#include "dsputil.h"
#include "get_bits.h"
#include "bytestream.h"
+#include "libavcore/audioconvert.h"
/**
* @file
@@ -199,7 +200,7 @@ static av_cold int ape_decode_init(AVCodecContext * avctx)
dsputil_init(&s->dsp, avctx);
avctx->sample_fmt = AV_SAMPLE_FMT_S16;
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
return 0;
}
diff --git a/libavcodec/audioconvert.h b/libavcodec/audioconvert.h
index be4867c22e..ae6016a611 100644
--- a/libavcodec/audioconvert.h
+++ b/libavcodec/audioconvert.h
@@ -31,6 +31,7 @@
#include "libavutil/cpu.h"
#include "avcodec.h"
+#include "libavcore/audioconvert.h"
#if FF_API_OLD_SAMPLE_FMT
/**
diff --git a/libavcodec/cook.c b/libavcodec/cook.c
index 6b70560546..9d3d001297 100644
--- a/libavcodec/cook.c
+++ b/libavcodec/cook.c
@@ -53,6 +53,7 @@
#include "dsputil.h"
#include "bytestream.h"
#include "fft.h"
+#include "libavcore/audioconvert.h"
#include "cookdata.h"
@@ -1274,7 +1275,7 @@ static av_cold int cook_decode_init(AVCodecContext *avctx)
if (channel_mask)
avctx->channel_layout = channel_mask;
else
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
#ifdef COOKDEBUG
dump_cook_context(q);
diff --git a/libavcodec/dca.c b/libavcodec/dca.c
index 63ea32992e..67195b1917 100644
--- a/libavcodec/dca.c
+++ b/libavcodec/dca.c
@@ -106,7 +106,7 @@ enum DCAExtensionMask {
* L = left, R = right, C = center, S = surround, F = front, R = rear, T = total, OV = overhead.
* S -> side, when both rear and back are configured move one of them to the side channel
* OV -> center back
- * All 2 channel configurations -> CH_LAYOUT_STEREO
+ * All 2 channel configurations -> AV_CH_LAYOUT_STEREO
*/
static const int64_t dca_core_channel_layout[] = {
@@ -117,7 +117,7 @@ static const int64_t dca_core_channel_layout[] = {
AV_CH_LAYOUT_STEREO, ///< 2, LT +RT (left and right total)
AV_CH_LAYOUT_STEREO|AV_CH_FRONT_CENTER, ///< 3, C+L+R
AV_CH_LAYOUT_STEREO|AV_CH_BACK_CENTER, ///< 3, L+R+S
- AV_CH_LAYOUT_STEREO|AV_CH_FRONT_CENTER|CH_BACK_CENTER, ///< 4, C + L + R+ S
+ AV_CH_LAYOUT_STEREO|AV_CH_FRONT_CENTER|AV_CH_BACK_CENTER, ///< 4, C + L + R+ S
AV_CH_LAYOUT_STEREO|AV_CH_SIDE_LEFT|AV_CH_SIDE_RIGHT, ///< 4, L + R +SL+ SR
AV_CH_LAYOUT_STEREO|AV_CH_FRONT_CENTER|AV_CH_SIDE_LEFT|AV_CH_SIDE_RIGHT, ///< 5, C + L + R+ SL+SR
AV_CH_LAYOUT_STEREO|AV_CH_SIDE_LEFT|AV_CH_SIDE_RIGHT|AV_CH_FRONT_LEFT_OF_CENTER|AV_CH_FRONT_RIGHT_OF_CENTER, ///< 6, CL + CR + L + R + SL + SR
diff --git a/libavcodec/imc.c b/libavcodec/imc.c
index 4d7fbd1db6..2b9de0b021 100644
--- a/libavcodec/imc.c
+++ b/libavcodec/imc.c
@@ -40,6 +40,7 @@
#include "get_bits.h"
#include "dsputil.h"
#include "fft.h"
+#include "libavcore/audioconvert.h"
#include "imcdata.h"
@@ -157,7 +158,7 @@ static av_cold int imc_decode_init(AVCodecContext * avctx)
ff_fft_init(&q->fft, 7, 1);
dsputil_init(&q->dsp, avctx);
avctx->sample_fmt = AV_SAMPLE_FMT_FLT;
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
return 0;
}
diff --git a/libavcodec/mpc7.c b/libavcodec/mpc7.c
index a77648f770..8bdb9e5813 100644
--- a/libavcodec/mpc7.c
+++ b/libavcodec/mpc7.c
@@ -30,6 +30,7 @@
#include "get_bits.h"
#include "dsputil.h"
#include "mpegaudio.h"
+#include "libavcore/audioconvert.h"
#include "mpc.h"
#include "mpc7data.h"
@@ -86,7 +87,7 @@ static av_cold int mpc7_decode_init(AVCodecContext * avctx)
c->frames_to_skip = 0;
avctx->sample_fmt = AV_SAMPLE_FMT_S16;
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
if(vlc_initialized) return 0;
av_log(avctx, AV_LOG_DEBUG, "Initing VLC\n");
diff --git a/libavcodec/mpc8.c b/libavcodec/mpc8.c
index 327a0c02f4..865ffc1b98 100644
--- a/libavcodec/mpc8.c
+++ b/libavcodec/mpc8.c
@@ -30,6 +30,7 @@
#include "get_bits.h"
#include "dsputil.h"
#include "mpegaudio.h"
+#include "libavcore/audioconvert.h"
#include "mpc.h"
#include "mpcdata.h"
@@ -135,7 +136,7 @@ static av_cold int mpc8_decode_init(AVCodecContext * avctx)
c->frames = 1 << (get_bits(&gb, 3) * 2);
avctx->sample_fmt = AV_SAMPLE_FMT_S16;
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
if(vlc_initialized) return 0;
av_log(avctx, AV_LOG_DEBUG, "Initing VLC\n");
diff --git a/libavcodec/smacker.c b/libavcodec/smacker.c
index fa8b4e3a18..61f1604616 100644
--- a/libavcodec/smacker.c
+++ b/libavcodec/smacker.c
@@ -32,6 +32,7 @@
#include <stdlib.h>
#include "avcodec.h"
+#include "libavcore/audioconvert.h"
#define ALT_BITSTREAM_READER_LE
#include "get_bits.h"
@@ -554,7 +555,7 @@ static av_cold int decode_end(AVCodecContext *avctx)
static av_cold int smka_decode_init(AVCodecContext *avctx)
{
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
avctx->sample_fmt = avctx->bits_per_coded_sample == 8 ? AV_SAMPLE_FMT_U8 : AV_SAMPLE_FMT_S16;
return 0;
}
diff --git a/libavcodec/vorbis_data.c b/libavcodec/vorbis_data.c
index 24c9921fd1..783a5daa00 100644
--- a/libavcodec/vorbis_data.c
+++ b/libavcodec/vorbis_data.c
@@ -20,6 +20,7 @@
#include "dsputil.h"
#include "vorbis.h"
+#include "libavcore/audioconvert.h"
const uint8_t ff_vorbis_channel_layout_offsets[8][8] = {
{ 0 },
@@ -44,14 +45,14 @@ const uint8_t ff_vorbis_encoding_channel_layout_offsets[8][8] = {
};
const int64_t ff_vorbis_channel_layouts[9] = {
- CH_LAYOUT_MONO,
- CH_LAYOUT_STEREO,
- CH_LAYOUT_SURROUND,
- CH_LAYOUT_QUAD,
- CH_LAYOUT_5POINT0_BACK,
- CH_LAYOUT_5POINT1_BACK,
- CH_LAYOUT_5POINT1|CH_BACK_CENTER,
- CH_LAYOUT_7POINT1,
+ AV_CH_LAYOUT_MONO,
+ AV_CH_LAYOUT_STEREO,
+ AV_CH_LAYOUT_SURROUND,
+ AV_CH_LAYOUT_QUAD,
+ AV_CH_LAYOUT_5POINT0_BACK,
+ AV_CH_LAYOUT_5POINT1_BACK,
+ AV_CH_LAYOUT_5POINT1|AV_CH_BACK_CENTER,
+ AV_CH_LAYOUT_7POINT1,
0
};
diff --git a/libavcodec/wavpack.c b/libavcodec/wavpack.c
index e96981460b..ffb5018c57 100644
--- a/libavcodec/wavpack.c
+++ b/libavcodec/wavpack.c
@@ -22,6 +22,7 @@
#include "avcodec.h"
#include "get_bits.h"
#include "unary.h"
+#include "libavcore/audioconvert.h"
/**
* @file
@@ -706,7 +707,7 @@ static av_cold int wavpack_decode_init(AVCodecContext *avctx)
else
avctx->sample_fmt = AV_SAMPLE_FMT_S32;
if(avctx->channels <= 2 && !avctx->channel_layout)
- avctx->channel_layout = (avctx->channels==2) ? CH_LAYOUT_STEREO : CH_LAYOUT_MONO;
+ avctx->channel_layout = (avctx->channels==2) ? AV_CH_LAYOUT_STEREO : AV_CH_LAYOUT_MONO;
s->multichannel = avctx->channels > 2;
/* lavf demuxer does not provide extradata, Matroska stores 0x403