diff options
author | Vittorio Giovara <vittorio.giovara@gmail.com> | 2017-03-31 18:04:05 +0200 |
---|---|---|
committer | James Almer <jamrial@gmail.com> | 2022-03-15 09:42:35 -0300 |
commit | 68559225a26251fcf8af9042f73b4a9dde7a4945 (patch) | |
tree | f2370bcf09ee1171b993e68f7da5b61df24df8e7 /libavformat/omaenc.c | |
parent | 5b51e6771c5419118dc02b325aafed37ce5cb709 (diff) | |
download | ffmpeg-68559225a26251fcf8af9042f73b4a9dde7a4945.tar.gz |
oma: convert to new channel layout API
Signed-off-by: Vittorio Giovara <vittorio.giovara@gmail.com>
Signed-off-by: Anton Khirnov <anton@khirnov.net>
Signed-off-by: James Almer <jamrial@gmail.com>
Diffstat (limited to 'libavformat/omaenc.c')
-rw-r--r-- | libavformat/omaenc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavformat/omaenc.c b/libavformat/omaenc.c index 1c4edcac5c..246f5195fb 100644 --- a/libavformat/omaenc.c +++ b/libavformat/omaenc.c @@ -58,7 +58,7 @@ static av_cold int oma_write_header(AVFormatContext *s) switch (par->codec_tag) { case OMA_CODECID_ATRAC3: - if (par->channels != 2) { + if (par->ch_layout.nb_channels != 2) { av_log(s, AV_LOG_ERROR, "ATRAC3 in OMA is only supported with 2 channels\n"); return AVERROR(EINVAL); } @@ -78,7 +78,7 @@ static av_cold int oma_write_header(AVFormatContext *s) case OMA_CODECID_ATRAC3P: avio_wb32(s->pb, (OMA_CODECID_ATRAC3P << 24) | (srate_index << 13) | - (par->channels << 10) | + (par->ch_layout.nb_channels << 10) | (par->block_align/8 - 1)); break; default: |