E-AC-3 passthrough requires an IEC 60958 frame rate of 4 times the
encoded sample rate as per the IEC 61937-3:2007 specification.
Currently AEStreamInfo uses a hardcoded value of 192kHz, causing streams
with a sample rate of less than 48kHz to be played back at an abnormally
fast rate.
Fix AEStreamInfo to use the correct value.
m_repeat = MAX_EAC3_BLOCKS / blocks;
- // sampling rate multiplied with number of channels must equal the value
- // given by the pack function
- m_outputRate = 192000;
+ // E-AC-3 rate is 4 times bitstream sample rate as per IEC 61937.
+ m_outputRate = 4 * m_sampleRate;
if (m_dataType == STREAM_TYPE_EAC3 && m_hasSync && skip == 0)
return 0;