Skip to content

Commit 5d576ba

Browse files
authored
Fix deprecation warning from new ffmpeg (#416)
Closes #415 Signed-off-by: Michael Carroll <[email protected]>
1 parent a27c7a1 commit 5d576ba

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

av/src/AudioDecoder.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -149,7 +149,7 @@ bool AudioDecoder::Decode(uint8_t **_outBuffer, unsigned int *_outBufferSize)
149149
// decodedFrame->linesize[0].
150150
int size = decodedFrame->nb_samples *
151151
av_get_bytes_per_sample(this->dataPtr->codecCtx->sample_fmt) *
152-
this->dataPtr->codecCtx->channels;
152+
this->dataPtr->codecCtx->ch_layout.nb_channels;
153153

154154
// Resize the audio buffer as necessary
155155
if (*_outBufferSize + size > maxBufferSize)

0 commit comments

Comments
 (0)