diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2011-04-16 23:20:48 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2011-04-16 23:24:10 +0200 |
commit | 1aeb88b77ddbd3802127a61bf8610e55b6c49a6f (patch) | |
tree | 784f8679e8f6a5ca5a7980e20e8b3b5fff47cbd4 /libavcodec/ac3.h | |
parent | bdf3d3bf9dce398acce608de77da205e08bdace3 (diff) | |
download | ffmpeg-1aeb88b77ddbd3802127a61bf8610e55b6c49a6f.tar.gz |
Correctly implement ac3 float/fixed encoder.
There is no need to have 2 encoders, the input sample format can,does and should choose which is used
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ac3.h')
-rw-r--r-- | libavcodec/ac3.h | 39 |
1 files changed, 39 insertions, 0 deletions
diff --git a/libavcodec/ac3.h b/libavcodec/ac3.h index 371d0a2532..6baf989394 100644 --- a/libavcodec/ac3.h +++ b/libavcodec/ac3.h @@ -38,6 +38,8 @@ #define AC3_CRITICAL_BANDS 50 #define AC3_MAX_CPL_BANDS 18 +#include "libavutil/opt.h" +#include "avcodec.h" #include "ac3tab.h" /* exponent encoding strategy */ @@ -128,8 +130,45 @@ typedef enum { EAC3_FRAME_TYPE_RESERVED } EAC3FrameType; +/** + * Encoding Options used by AVOption. + */ +typedef struct AC3EncOptions { + /* AC-3 metadata options*/ + int dialogue_level; + int bitstream_mode; + float center_mix_level; + float surround_mix_level; + int dolby_surround_mode; + int audio_production_info; + int mixing_level; + int room_type; + int copyright; + int original; + int extended_bsi_1; + int preferred_stereo_downmix; + float ltrt_center_mix_level; + float ltrt_surround_mix_level; + float loro_center_mix_level; + float loro_surround_mix_level; + int extended_bsi_2; + int dolby_surround_ex_mode; + int dolby_headphone_mode; + int ad_converter_type; + + /* other encoding options */ + int allow_per_frame_metadata; +} AC3EncOptions; + + void ff_ac3_common_init(void); +extern const int64_t ff_ac3_channel_layouts[]; +extern const AVOption ff_ac3_options[]; + +extern AVCodec ff_ac3_float_encoder; +extern AVCodec ff_ac3_fixed_encoder; + /** * Calculate the log power-spectral density of the input signal. * This gives a rough estimate of signal power in the frequency domain by using |