summaryrefslogtreecommitdiff
path: root/libavcodec/ac3enc.h
diff options
context:
space:
mode:
Diffstat (limited to 'libavcodec/ac3enc.h')
-rw-r--r--libavcodec/ac3enc.h22
1 files changed, 8 insertions, 14 deletions
diff --git a/libavcodec/ac3enc.h b/libavcodec/ac3enc.h
index ccef7079e4..6caf4d80c4 100644
--- a/libavcodec/ac3enc.h
+++ b/libavcodec/ac3enc.h
@@ -66,11 +66,6 @@ typedef int64_t CoefSumType;
#endif
-typedef struct AC3MDCTContext {
- const SampleType *window; ///< MDCT window function
- FFTContext fft; ///< FFT context for MDCT calculation
-} AC3MDCTContext;
-
/**
* Encoding Options used by AVOption.
*/
@@ -143,7 +138,8 @@ typedef struct AC3EncodeContext {
PutBitContext pb; ///< bitstream writer context
DSPContext dsp;
AC3DSPContext ac3dsp; ///< AC-3 optimized functions
- AC3MDCTContext *mdct; ///< MDCT context
+ FFTContext mdct; ///< FFT context for MDCT calculation
+ const SampleType *mdct_window; ///< MDCT window function array
AC3Block blocks[AC3_MAX_BLOCKS]; ///< per-block info
@@ -226,8 +222,8 @@ typedef struct AC3EncodeContext {
int ref_bap_set; ///< indicates if ref_bap pointers have been set
/* fixed vs. float function pointers */
- void (*mdct_end)(AC3MDCTContext *mdct);
- int (*mdct_init)(AVCodecContext *avctx, AC3MDCTContext *mdct, int nbits);
+ void (*mdct_end)(struct AC3EncodeContext *s);
+ int (*mdct_init)(struct AC3EncodeContext *s);
/* fixed vs. float templated function pointers */
int (*allocate_sample_buffers)(struct AC3EncodeContext *s);
@@ -262,13 +258,11 @@ void ff_ac3_output_frame(AC3EncodeContext *s, unsigned char *frame);
/* prototypes for functions in ac3enc_fixed.c and ac3enc_float.c */
-void ff_ac3_fixed_mdct_end(AC3MDCTContext *mdct);
-void ff_ac3_float_mdct_end(AC3MDCTContext *mdct);
+void ff_ac3_fixed_mdct_end(AC3EncodeContext *s);
+void ff_ac3_float_mdct_end(AC3EncodeContext *s);
-int ff_ac3_fixed_mdct_init(AVCodecContext *avctx, AC3MDCTContext *mdct,
- int nbits);
-int ff_ac3_float_mdct_init(AVCodecContext *avctx, AC3MDCTContext *mdct,
- int nbits);
+int ff_ac3_fixed_mdct_init(AC3EncodeContext *s);
+int ff_ac3_float_mdct_init(AC3EncodeContext *s);
/* prototypes for functions in ac3enc_template.c */