Skip to content

Commit 72b7f4d

Browse files
author
Clement Champetier
committed
AudioDecoder: removed check of nbChannel when extract one channel in an audio stream
* Revert of commit e5f16f7 * The user has to check what he wants to decode (it will work, but it is more expensive to try to extract one channel than only decode the frame).
1 parent 7957627 commit 72b7f4d

File tree

1 file changed

+0
-6
lines changed

1 file changed

+0
-6
lines changed

src/AvTranscoder/decoder/AudioDecoder.cpp

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -116,12 +116,6 @@ bool AudioDecoder::decodeNextFrame(Frame& frameBuffer, const size_t channelIndex
116116
{
117117
AudioFrame& audioBuffer = static_cast<AudioFrame&>(frameBuffer);
118118

119-
// if no need to extract one channel in the audio stream
120-
if(audioBuffer.getNbChannels() == 1 && channelIndex == 0)
121-
{
122-
return decodeNextFrame(frameBuffer);
123-
}
124-
125119
// decode all data of the next frame
126120
AudioFrame allDataOfNextFrame(audioBuffer);
127121
if(!decodeNextFrame(allDataOfNextFrame))

0 commit comments

Comments
 (0)