aboutsummaryrefslogtreecommitdiff
path: root/libavformat/ape.c
diff options
context:
space:
mode:
authorDerek Buitenhuis2016-04-10 20:58:15 +0100
committerDerek Buitenhuis2016-04-10 20:59:55 +0100
commit6f69f7a8bf6a0d013985578df2ef42ee6b1c7994 (patch)
tree0c2ec8349ff1763d5f48454b8b9f26374dbd80b0 /libavformat/ape.c
parent60b75186b2c878b6257b43c8fcc0b1356ada218e (diff)
parent9200514ad8717c63f82101dc394f4378854325bf (diff)
Merge commit '9200514ad8717c63f82101dc394f4378854325bf'
* commit '9200514ad8717c63f82101dc394f4378854325bf': lavf: replace AVStream.codec with AVStream.codecpar This has been a HUGE effort from: - Derek Buitenhuis <derek.buitenhuis@gmail.com> - Hendrik Leppkes <h.leppkes@gmail.com> - wm4 <nfxjfg@googlemail.com> - Clément Bœsch <clement@stupeflix.com> - James Almer <jamrial@gmail.com> - Michael Niedermayer <michael@niedermayer.cc> - Rostislav Pehlivanov <atomnuker@gmail.com> Merged-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Diffstat (limited to 'libavformat/ape.c')
-rw-r--r--libavformat/ape.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/libavformat/ape.c b/libavformat/ape.c
index 3e819728cc..061f32866f 100644
--- a/libavformat/ape.c
+++ b/libavformat/ape.c
@@ -348,23 +348,23 @@ static int ape_read_header(AVFormatContext * s)
total_blocks = (ape->totalframes == 0) ? 0 : ((ape->totalframes - 1) * ape->blocksperframe) + ape->finalframeblocks;
- st->codec->codec_type = AVMEDIA_TYPE_AUDIO;
- st->codec->codec_id = AV_CODEC_ID_APE;
- st->codec->codec_tag = MKTAG('A', 'P', 'E', ' ');
- st->codec->channels = ape->channels;
- st->codec->sample_rate = ape->samplerate;
- st->codec->bits_per_coded_sample = ape->bps;
+ st->codecpar->codec_type = AVMEDIA_TYPE_AUDIO;
+ st->codecpar->codec_id = AV_CODEC_ID_APE;
+ st->codecpar->codec_tag = MKTAG('A', 'P', 'E', ' ');
+ st->codecpar->channels = ape->channels;
+ st->codecpar->sample_rate = ape->samplerate;
+ st->codecpar->bits_per_coded_sample = ape->bps;
st->nb_frames = ape->totalframes;
st->start_time = 0;
st->duration = total_blocks;
avpriv_set_pts_info(st, 64, 1, ape->samplerate);
- if (ff_alloc_extradata(st->codec, APE_EXTRADATA_SIZE))
+ if (ff_alloc_extradata(st->codecpar, APE_EXTRADATA_SIZE))
return AVERROR(ENOMEM);
- AV_WL16(st->codec->extradata + 0, ape->fileversion);
- AV_WL16(st->codec->extradata + 2, ape->compressiontype);
- AV_WL16(st->codec->extradata + 4, ape->formatflags);
+ AV_WL16(st->codecpar->extradata + 0, ape->fileversion);
+ AV_WL16(st->codecpar->extradata + 2, ape->compressiontype);
+ AV_WL16(st->codecpar->extradata + 4, ape->formatflags);
pts = 0;
for (i = 0; i < ape->totalframes; i++) {