Revision af704ee4

View differences:

libavformat/electronicarts.c
40 40
#define EA_PREAMBLE_SIZE 8
41 41

  
42 42
typedef struct EaDemuxContext {
43
    int video_codec;
43 44
    AVRational time_base;
44 45
    int video_stream_index;
45 46

  
47
    int audio_codec;
46 48
    int audio_stream_index;
47 49
    int audio_frame_counter;
48 50

  
......
134 136
        }
135 137
    }
136 138

  
139
    ea->audio_codec = CODEC_ID_ADPCM_EA;
140

  
137 141
    return 1;
138 142
}
139 143

  
......
145 149
    url_fskip(pb, 16);
146 150
    ea->time_base.den = get_le32(pb);
147 151
    ea->time_base.num = get_le32(pb);
152
    ea->video_codec = CODEC_ID_VP6;
148 153

  
149 154
    return 1;
150 155
}
......
212 217
            return AVERROR(ENOMEM);
213 218
        ea->video_stream_index = st->index;
214 219
        st->codec->codec_type = CODEC_TYPE_VIDEO;
215
        st->codec->codec_id = CODEC_ID_VP6;
220
        st->codec->codec_id = ea->video_codec;
216 221
        st->codec->codec_tag = 0;  /* no fourcc */
217 222
        st->codec->time_base = ea->time_base;
218 223
    }
......
223 228
        return AVERROR(ENOMEM);
224 229
    av_set_pts_info(st, 33, 1, EA_SAMPLE_RATE);
225 230
    st->codec->codec_type = CODEC_TYPE_AUDIO;
226
    st->codec->codec_id = CODEC_ID_ADPCM_EA;
231
    st->codec->codec_id = ea->audio_codec;
227 232
    st->codec->codec_tag = 0;  /* no tag */
228 233
    st->codec->channels = ea->num_channels;
229 234
    st->codec->sample_rate = EA_SAMPLE_RATE;

Also available in: Unified diff