Revision 72415b2a libavformat/iff.c

View differences:

libavformat/iff.c
119 119

  
120 120
        switch(chunk_id) {
121 121
        case ID_VHDR:
122
            st->codec->codec_type = CODEC_TYPE_AUDIO;
122
            st->codec->codec_type = AVMEDIA_TYPE_AUDIO;
123 123
            url_fskip(pb, 12);
124 124
            st->codec->sample_rate = get_be16(pb);
125 125
            url_fskip(pb, 1);
......
146 146
            break;
147 147

  
148 148
        case ID_BMHD:
149
            st->codec->codec_type            = CODEC_TYPE_VIDEO;
149
            st->codec->codec_type            = AVMEDIA_TYPE_VIDEO;
150 150
            st->codec->width                 = get_be16(pb);
151 151
            st->codec->height                = get_be16(pb);
152 152
            url_fskip(pb, 4); // x, y offset
......
175 175
    }
176 176

  
177 177
    switch(st->codec->codec_type) {
178
    case CODEC_TYPE_AUDIO:
178
    case AVMEDIA_TYPE_AUDIO:
179 179
    av_set_pts_info(st, 32, 1, st->codec->sample_rate);
180 180

  
181 181
    switch(compression) {
......
198 198
    st->codec->block_align = st->codec->channels * st->codec->bits_per_coded_sample;
199 199
    break;
200 200

  
201
    case CODEC_TYPE_VIDEO:
201
    case AVMEDIA_TYPE_VIDEO:
202 202
        switch (compression) {
203 203
        case BITMAP_RAW:
204 204
            if (st->codec->codec_tag == ID_ILBM) {
......
256 256
        st->codec->extradata_size = 0;
257 257

  
258 258
        ret = get_buffer(pb, pkt->data, iff->body_size);
259
    } else if (s->streams[0]->codec->codec_type == CODEC_TYPE_VIDEO) {
259
    } else if (s->streams[0]->codec->codec_type == AVMEDIA_TYPE_VIDEO) {
260 260
        ret = av_get_packet(pb, pkt, iff->body_size);
261 261
    } else {
262 262
        ret = av_get_packet(pb, pkt, PACKET_SIZE);
......
265 265
    if(iff->sent_bytes == 0)
266 266
        pkt->flags |= PKT_FLAG_KEY;
267 267

  
268
    if(s->streams[0]->codec->codec_type == CODEC_TYPE_AUDIO) {
268
    if(s->streams[0]->codec->codec_type == AVMEDIA_TYPE_AUDIO) {
269 269
        iff->sent_bytes += PACKET_SIZE;
270 270
    } else {
271 271
        iff->sent_bytes = iff->body_size;
272 272
    }
273 273
    pkt->stream_index = 0;
274
    if(s->streams[0]->codec->codec_type == CODEC_TYPE_AUDIO) {
274
    if(s->streams[0]->codec->codec_type == AVMEDIA_TYPE_AUDIO) {
275 275
        pkt->pts = iff->audio_frame_count;
276 276
        iff->audio_frame_count += ret / s->streams[0]->codec->channels;
277 277
    }

Also available in: Unified diff