mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
avformat/imfdec: Convert to the new channel layout API
Reviewed-by: James Almer <jamrial@gmail.com> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
242c07982a
commit
814f806e06
@ -874,7 +874,7 @@ static int imf_read_packet(AVFormatContext *s, AVPacket *pkt)
|
|||||||
int64_t nbsamples = av_rescale_q(pkt->duration,
|
int64_t nbsamples = av_rescale_q(pkt->duration,
|
||||||
st->time_base,
|
st->time_base,
|
||||||
av_make_q(1, st->codecpar->sample_rate));
|
av_make_q(1, st->codecpar->sample_rate));
|
||||||
av_shrink_packet(pkt, nbsamples * st->codecpar->channels * bytes_per_sample);
|
av_shrink_packet(pkt, nbsamples * st->codecpar->ch_layout.nb_channels * bytes_per_sample);
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
/* in all other cases, use side data to skip samples */
|
/* in all other cases, use side data to skip samples */
|
||||||
|
Loading…
Reference in New Issue
Block a user