Commit c6736713 authored by Clément Bœsch's avatar Clément Bœsch Committed by Clément Bœsch

ffmpeg: fix -map_channel being ignored when resampling is not needed.

parent 151ecc2a
...@@ -1245,7 +1245,7 @@ need_realloc: ...@@ -1245,7 +1245,7 @@ need_realloc:
ost->sync_opts = lrintf(get_sync_ipts(ost) * enc->sample_rate) - ost->sync_opts = lrintf(get_sync_ipts(ost) * enc->sample_rate) -
av_fifo_size(ost->fifo) / (enc->channels * osize); // FIXME wrong av_fifo_size(ost->fifo) / (enc->channels * osize); // FIXME wrong
if (ost->audio_resample) { if (ost->audio_resample || ost->audio_channels_mapped) {
buftmp = audio_buf; buftmp = audio_buf;
size_out = swr_convert(ost->swr, ( uint8_t*[]){buftmp}, audio_buf_size / (enc->channels * osize), size_out = swr_convert(ost->swr, ( uint8_t*[]){buftmp}, audio_buf_size / (enc->channels * osize),
(const uint8_t*[]){buf }, size / (dec->channels * isize)); (const uint8_t*[]){buf }, size / (dec->channels * isize));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment