summaryrefslogtreecommitdiff
path: root/libavcodec/ac3enc_fixed.c
diff options
context:
space:
mode:
authorJustin Ruggles <justin.ruggles@gmail.com>2011-06-26 23:58:19 -0400
committerJustin Ruggles <justin.ruggles@gmail.com>2011-06-27 12:59:39 -0400
commit8683c6a638f2e323d11b520c5e130b46b1eb1eda (patch)
treefa28e7001bd355e58abd2bbbe3af8b43530a0758 /libavcodec/ac3enc_fixed.c
parent668afae438ec8502517abb1c001b984c649e5e95 (diff)
ac3enc: move ff_ac3_encode_frame() to ac3enc_template.c
This avoids using function pointers for quite a few small functions, most of which just call DSP functions.
Diffstat (limited to 'libavcodec/ac3enc_fixed.c')
-rw-r--r--libavcodec/ac3enc_fixed.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/libavcodec/ac3enc_fixed.c b/libavcodec/ac3enc_fixed.c
index 32ff405247..d55720eb80 100644
--- a/libavcodec/ac3enc_fixed.c
+++ b/libavcodec/ac3enc_fixed.c
@@ -63,9 +63,8 @@ av_cold int AC3_NAME(mdct_init)(AVCodecContext *avctx, AC3MDCTContext *mdct,
/**
* Apply KBD window to input samples prior to MDCT.
*/
-void AC3_NAME(apply_window)(DSPContext *dsp, int16_t *output,
- const int16_t *input, const int16_t *window,
- unsigned int len)
+static void apply_window(DSPContext *dsp, int16_t *output, const int16_t *input,
+ const int16_t *window, unsigned int len)
{
dsp->apply_window_int16(output, input, window, len);
}
@@ -77,7 +76,7 @@ void AC3_NAME(apply_window)(DSPContext *dsp, int16_t *output,
*
* @return exponent shift
*/
-int AC3_NAME(normalize_samples)(AC3EncodeContext *s)
+static int normalize_samples(AC3EncodeContext *s)
{
int v = s->ac3dsp.ac3_max_msb_abs_int16(s->windowed_samples, AC3_WINDOW_SIZE);
v = 14 - av_log2(v);
@@ -91,7 +90,7 @@ int AC3_NAME(normalize_samples)(AC3EncodeContext *s)
/**
* Scale MDCT coefficients to 25-bit signed fixed-point.
*/
-void AC3_NAME(scale_coefficients)(AC3EncodeContext *s)
+static void scale_coefficients(AC3EncodeContext *s)
{
int blk, ch;
@@ -119,7 +118,7 @@ AVCodec ff_ac3_fixed_encoder = {
CODEC_ID_AC3,
sizeof(AC3EncodeContext),
ac3_fixed_encode_init,
- ff_ac3_encode_frame,
+ ff_ac3_fixed_encode_frame,
ff_ac3_encode_close,
NULL,
.sample_fmts = (const enum AVSampleFormat[]){AV_SAMPLE_FMT_S16,AV_SAMPLE_FMT_NONE},