From 6e82930326b9f30fe786b5ed3dd3b74a6e751f6c Mon Sep 17 00:00:00 2001 From: Stefan Pöschel Date: Thu, 7 May 2015 20:59:21 +0200 Subject: Use 960-transformation in libfaad2 Previously the (default) 1024-transformation was used for PCM output, although DAB+ uses the 960-transformation. This lead to audio being slower and lower than the original source. In libfaad2 the 960-transformation can be enabled by using a carefully crafted AudioSpecificConfig for initialization, which is carried out by this commit. --- faad_decoder.h | 23 +---------------------- 1 file changed, 1 insertion(+), 22 deletions(-) (limited to 'faad_decoder.h') diff --git a/faad_decoder.h b/faad_decoder.h index 1a14efb..b84913c 100644 --- a/faad_decoder.h +++ b/faad_decoder.h @@ -33,27 +33,6 @@ #ifndef __FAAD_DECODER_H_ #define __FAAD_DECODER_H_ -struct adts_fixed_header { - unsigned int syncword :12; - unsigned int id :1; - unsigned int layer :2; - unsigned int protection_absent :1; - unsigned int profile_objecttype :2; - unsigned int sampling_freq_idx :4; - unsigned int private_bit :1; - unsigned int channel_conf :3; - unsigned int original_copy :1; - unsigned int home :1; -}; - -struct adts_variable_header { - unsigned int copyright_id_bit :1; - unsigned int copyright_id_start :1; - unsigned int aac_frame_length :13; - unsigned int adts_buffer_fullness :11; - unsigned int no_raw_data_blocks :2; -}; - class FaadHandle { public: @@ -97,7 +76,7 @@ class FaadDecoder bool is_initialised(void) { return m_initialised; } private: - void update_header(void); + int get_aac_channel_configuration(); size_t m_data_len; std::string m_filename; -- cgit v1.2.3