Mercurial > libavformat.hg
annotate 4xm.c @ 2303:36009df78f49 libavformat
increase the maximum AC3 probe buffer size and reduce the threshold for 50% reliability score to 2 frames. Fixes out.ac3 from [FFmpeg-devel] AC3 Format Detection unreliable.
author | jbr |
---|---|
date | Sat, 04 Aug 2007 23:53:05 +0000 |
parents | b21c2af60bc9 |
children | 2a44e9c75bf3 |
rev | line source |
---|---|
137 | 1 /* |
2 * 4X Technologies .4xm File Demuxer (no muxer) | |
3 * Copyright (c) 2003 The ffmpeg Project | |
4 * | |
1358
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
5 * This file is part of FFmpeg. |
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
6 * |
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
7 * FFmpeg is free software; you can redistribute it and/or |
137 | 8 * modify it under the terms of the GNU Lesser General Public |
9 * License as published by the Free Software Foundation; either | |
1358
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
10 * version 2.1 of the License, or (at your option) any later version. |
137 | 11 * |
1358
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
12 * FFmpeg is distributed in the hope that it will be useful, |
137 | 13 * but WITHOUT ANY WARRANTY; without even the implied warranty of |
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
15 * Lesser General Public License for more details. | |
16 * | |
17 * You should have received a copy of the GNU Lesser General Public | |
1358
0899bfe4105c
Change license headers to say 'FFmpeg' instead of 'this program/this library'
diego
parents:
1169
diff
changeset
|
18 * License along with FFmpeg; if not, write to the Free Software |
896
edbe5c3717f9
Update licensing information: The FSF changed postal address.
diego
parents:
885
diff
changeset
|
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
137 | 20 */ |
21 | |
22 /** | |
23 * @file 4xm.c | |
24 * 4X Technologies file demuxer | |
25 * by Mike Melanson (melanson@pcisys.net) | |
26 * for more information on the .4xm file format, visit: | |
27 * http://www.pcisys.net/~melanson/codecs/ | |
28 */ | |
29 | |
30 #include "avformat.h" | |
31 | |
386
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
32 #define RIFF_TAG MKTAG('R', 'I', 'F', 'F') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
33 #define _4XMV_TAG MKTAG('4', 'X', 'M', 'V') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
34 #define LIST_TAG MKTAG('L', 'I', 'S', 'T') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
35 #define HEAD_TAG MKTAG('H', 'E', 'A', 'D') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
36 #define TRK__TAG MKTAG('T', 'R', 'K', '_') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
37 #define MOVI_TAG MKTAG('M', 'O', 'V', 'I') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
38 #define VTRK_TAG MKTAG('V', 'T', 'R', 'K') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
39 #define STRK_TAG MKTAG('S', 'T', 'R', 'K') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
40 #define std__TAG MKTAG('s', 't', 'd', '_') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
41 #define name_TAG MKTAG('n', 'a', 'm', 'e') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
42 #define vtrk_TAG MKTAG('v', 't', 'r', 'k') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
43 #define strk_TAG MKTAG('s', 't', 'r', 'k') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
44 #define ifrm_TAG MKTAG('i', 'f', 'r', 'm') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
45 #define pfrm_TAG MKTAG('p', 'f', 'r', 'm') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
46 #define cfrm_TAG MKTAG('c', 'f', 'r', 'm') |
c152849ee643
remove numerous definitions of BE_*/LE_* macros; convert FOURCC_TAG ->
melanson
parents:
317
diff
changeset
|
47 #define snd__TAG MKTAG('s', 'n', 'd', '_') |
137 | 48 |
49 #define vtrk_SIZE 0x44 | |
50 #define strk_SIZE 0x28 | |
51 | |
52 #define GET_LIST_HEADER() \ | |
143 | 53 fourcc_tag = get_le32(pb); \ |
137 | 54 size = get_le32(pb); \ |
55 if (fourcc_tag != LIST_TAG) \ | |
56 return AVERROR_INVALIDDATA; \ | |
143 | 57 fourcc_tag = get_le32(pb); |
137 | 58 |
59 typedef struct AudioTrack { | |
60 int sample_rate; | |
61 int bits; | |
62 int channels; | |
143 | 63 int stream_index; |
145 | 64 int adpcm; |
137 | 65 } AudioTrack; |
66 | |
67 typedef struct FourxmDemuxContext { | |
68 int width; | |
69 int height; | |
143 | 70 int video_stream_index; |
137 | 71 int track_count; |
72 AudioTrack *tracks; | |
73 int selected_track; | |
143 | 74 |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
75 int64_t audio_pts; |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
76 int64_t video_pts; |
317 | 77 float fps; |
137 | 78 } FourxmDemuxContext; |
79 | |
80 static int fourxm_probe(AVProbeData *p) | |
81 { | |
1673 | 82 if ((AV_RL32(&p->buf[0]) != RIFF_TAG) || |
83 (AV_RL32(&p->buf[8]) != _4XMV_TAG)) | |
137 | 84 return 0; |
85 | |
86 return AVPROBE_SCORE_MAX; | |
87 } | |
88 | |
89 static int fourxm_read_header(AVFormatContext *s, | |
143 | 90 AVFormatParameters *ap) |
137 | 91 { |
92 ByteIOContext *pb = &s->pb; | |
93 unsigned int fourcc_tag; | |
94 unsigned int size; | |
95 int header_size; | |
2006 | 96 FourxmDemuxContext *fourxm = s->priv_data; |
137 | 97 unsigned char *header; |
98 int i; | |
99 int current_track = -1; | |
100 AVStream *st; | |
101 | |
102 fourxm->track_count = 0; | |
103 fourxm->tracks = NULL; | |
104 fourxm->selected_track = 0; | |
317 | 105 fourxm->fps = 1.0; |
137 | 106 |
107 /* skip the first 3 32-bit numbers */ | |
108 url_fseek(pb, 12, SEEK_CUR); | |
109 | |
110 /* check for LIST-HEAD */ | |
111 GET_LIST_HEADER(); | |
112 header_size = size - 4; | |
113 if (fourcc_tag != HEAD_TAG) | |
114 return AVERROR_INVALIDDATA; | |
115 | |
116 /* allocate space for the header and load the whole thing */ | |
117 header = av_malloc(header_size); | |
118 if (!header) | |
2273
7eb456c4ed8a
Replace all occurrences of AVERROR_NOMEM with AVERROR(ENOMEM).
takis
parents:
2006
diff
changeset
|
119 return AVERROR(ENOMEM); |
137 | 120 if (get_buffer(pb, header, header_size) != header_size) |
2274
b21c2af60bc9
Replace all occurrences of AVERROR_IO with AVERROR(EIO).
takis
parents:
2273
diff
changeset
|
121 return AVERROR(EIO); |
137 | 122 |
123 /* take the lazy approach and search for any and all vtrk and strk chunks */ | |
124 for (i = 0; i < header_size - 8; i++) { | |
1673 | 125 fourcc_tag = AV_RL32(&header[i]); |
126 size = AV_RL32(&header[i + 4]); | |
137 | 127 |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
128 if (fourcc_tag == std__TAG) { |
1673 | 129 fourxm->fps = av_int2flt(AV_RL32(&header[i + 12])); |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
130 } else if (fourcc_tag == vtrk_TAG) { |
137 | 131 /* check that there is enough data */ |
132 if (size != vtrk_SIZE) { | |
133 av_free(header); | |
134 return AVERROR_INVALIDDATA; | |
135 } | |
1673 | 136 fourxm->width = AV_RL32(&header[i + 36]); |
137 fourxm->height = AV_RL32(&header[i + 40]); | |
137 | 138 i += 8 + size; |
143 | 139 |
140 /* allocate a new AVStream */ | |
141 st = av_new_stream(s, 0); | |
142 if (!st) | |
2273
7eb456c4ed8a
Replace all occurrences of AVERROR_NOMEM with AVERROR(ENOMEM).
takis
parents:
2006
diff
changeset
|
143 return AVERROR(ENOMEM); |
740 | 144 av_set_pts_info(st, 60, 1, fourxm->fps); |
143 | 145 |
146 fourxm->video_stream_index = st->index; | |
147 | |
820
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
148 st->codec->codec_type = CODEC_TYPE_VIDEO; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
149 st->codec->codec_id = CODEC_ID_4XM; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
150 st->codec->codec_tag = 0; /* no fourcc */ |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
151 st->codec->width = fourxm->width; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
152 st->codec->height = fourxm->height; |
143 | 153 |
137 | 154 } else if (fourcc_tag == strk_TAG) { |
155 /* check that there is enough data */ | |
156 if (size != strk_SIZE) { | |
157 av_free(header); | |
158 return AVERROR_INVALIDDATA; | |
159 } | |
1673 | 160 current_track = AV_RL32(&header[i + 8]); |
137 | 161 if (current_track + 1 > fourxm->track_count) { |
141 | 162 fourxm->track_count = current_track + 1; |
639 | 163 if((unsigned)fourxm->track_count >= UINT_MAX / sizeof(AudioTrack)) |
164 return -1; | |
885 | 165 fourxm->tracks = av_realloc(fourxm->tracks, |
141 | 166 fourxm->track_count * sizeof(AudioTrack)); |
137 | 167 if (!fourxm->tracks) { |
168 av_free(header); | |
2273
7eb456c4ed8a
Replace all occurrences of AVERROR_NOMEM with AVERROR(ENOMEM).
takis
parents:
2006
diff
changeset
|
169 return AVERROR(ENOMEM); |
137 | 170 } |
171 } | |
1673 | 172 fourxm->tracks[current_track].adpcm = AV_RL32(&header[i + 12]); |
173 fourxm->tracks[current_track].channels = AV_RL32(&header[i + 36]); | |
174 fourxm->tracks[current_track].sample_rate = AV_RL32(&header[i + 40]); | |
175 fourxm->tracks[current_track].bits = AV_RL32(&header[i + 44]); | |
137 | 176 i += 8 + size; |
143 | 177 |
178 /* allocate a new AVStream */ | |
179 st = av_new_stream(s, current_track); | |
180 if (!st) | |
2273
7eb456c4ed8a
Replace all occurrences of AVERROR_NOMEM with AVERROR(ENOMEM).
takis
parents:
2006
diff
changeset
|
181 return AVERROR(ENOMEM); |
143 | 182 |
740 | 183 av_set_pts_info(st, 60, 1, fourxm->tracks[current_track].sample_rate); |
462
b69898ffc92a
move time_base (pts_num/pts_den) from AVFormatContext -> AVStream
michael
parents:
386
diff
changeset
|
184 |
143 | 185 fourxm->tracks[current_track].stream_index = st->index; |
186 | |
820
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
187 st->codec->codec_type = CODEC_TYPE_AUDIO; |
1450
1580c48ba4b9
Do not set audio codec_tag to 1, that would be PCM audio.
diego
parents:
1358
diff
changeset
|
188 st->codec->codec_tag = 0; |
820
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
189 st->codec->channels = fourxm->tracks[current_track].channels; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
190 st->codec->sample_rate = fourxm->tracks[current_track].sample_rate; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
191 st->codec->bits_per_sample = fourxm->tracks[current_track].bits; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
192 st->codec->bit_rate = st->codec->channels * st->codec->sample_rate * |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
193 st->codec->bits_per_sample; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
194 st->codec->block_align = st->codec->channels * st->codec->bits_per_sample; |
145 | 195 if (fourxm->tracks[current_track].adpcm) |
820
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
196 st->codec->codec_id = CODEC_ID_ADPCM_4XM; |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
197 else if (st->codec->bits_per_sample == 8) |
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
198 st->codec->codec_id = CODEC_ID_PCM_U8; |
143 | 199 else |
820
feca73904e67
changing AVCodecContext codec -> *codec in AVStream so additions to AVCodecContext dont randomize AVStream and break binary compatibility
michael
parents:
775
diff
changeset
|
200 st->codec->codec_id = CODEC_ID_PCM_S16LE; |
137 | 201 } |
202 } | |
203 | |
204 av_free(header); | |
205 | |
206 /* skip over the LIST-MOVI chunk (which is where the stream should be */ | |
207 GET_LIST_HEADER(); | |
208 if (fourcc_tag != MOVI_TAG) | |
209 return AVERROR_INVALIDDATA; | |
210 | |
143 | 211 /* initialize context members */ |
740 | 212 fourxm->video_pts = -1; /* first frame will push to 0 */ |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
213 fourxm->audio_pts = 0; |
137 | 214 |
215 return 0; | |
216 } | |
217 | |
218 static int fourxm_read_packet(AVFormatContext *s, | |
143 | 219 AVPacket *pkt) |
137 | 220 { |
221 FourxmDemuxContext *fourxm = s->priv_data; | |
222 ByteIOContext *pb = &s->pb; | |
223 unsigned int fourcc_tag; | |
145 | 224 unsigned int size, out_size; |
137 | 225 int ret = 0; |
226 int track_number; | |
227 int packet_read = 0; | |
143 | 228 unsigned char header[8]; |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
229 int audio_frame_count; |
137 | 230 |
231 while (!packet_read) { | |
232 | |
143 | 233 if ((ret = get_buffer(&s->pb, header, 8)) < 0) |
234 return ret; | |
1673 | 235 fourcc_tag = AV_RL32(&header[0]); |
236 size = AV_RL32(&header[4]); | |
137 | 237 if (url_feof(pb)) |
2274
b21c2af60bc9
Replace all occurrences of AVERROR_IO with AVERROR(EIO).
takis
parents:
2273
diff
changeset
|
238 return AVERROR(EIO); |
137 | 239 switch (fourcc_tag) { |
240 | |
144 | 241 case LIST_TAG: |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
242 /* this is a good time to bump the video pts */ |
740 | 243 fourxm->video_pts ++; |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
244 |
144 | 245 /* skip the LIST-* tag and move on to the next fourcc */ |
246 get_le32(pb); | |
247 break; | |
248 | |
137 | 249 case ifrm_TAG: |
250 case pfrm_TAG: | |
139 | 251 case cfrm_TAG:{ |
143 | 252 |
253 /* allocate 8 more bytes than 'size' to account for fourcc | |
254 * and size */ | |
643 | 255 if (size + 8 < size || av_new_packet(pkt, size + 8)) |
2274
b21c2af60bc9
Replace all occurrences of AVERROR_IO with AVERROR(EIO).
takis
parents:
2273
diff
changeset
|
256 return AVERROR(EIO); |
143 | 257 pkt->stream_index = fourxm->video_stream_index; |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
258 pkt->pts = fourxm->video_pts; |
775 | 259 pkt->pos = url_ftell(&s->pb); |
143 | 260 memcpy(pkt->data, header, 8); |
261 ret = get_buffer(&s->pb, &pkt->data[8], size); | |
262 | |
263 if (ret < 0) | |
264 av_free_packet(pkt); | |
265 else | |
266 packet_read = 1; | |
139 | 267 break; |
268 } | |
143 | 269 |
137 | 270 case snd__TAG: |
271 track_number = get_le32(pb); | |
145 | 272 out_size= get_le32(pb); |
273 size-=8; | |
274 | |
137 | 275 if (track_number == fourxm->selected_track) { |
775 | 276 ret= av_get_packet(&s->pb, pkt, size); |
277 if(ret<0) | |
2274
b21c2af60bc9
Replace all occurrences of AVERROR_IO with AVERROR(EIO).
takis
parents:
2273
diff
changeset
|
278 return AVERROR(EIO); |
885 | 279 pkt->stream_index = |
143 | 280 fourxm->tracks[fourxm->selected_track].stream_index; |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
281 pkt->pts = fourxm->audio_pts; |
775 | 282 packet_read = 1; |
143 | 283 |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
284 /* pts accounting */ |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
285 audio_frame_count = size; |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
286 if (fourxm->tracks[fourxm->selected_track].adpcm) |
885 | 287 audio_frame_count -= |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
288 2 * (fourxm->tracks[fourxm->selected_track].channels); |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
289 audio_frame_count /= |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
290 fourxm->tracks[fourxm->selected_track].channels; |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
291 if (fourxm->tracks[fourxm->selected_track].adpcm) |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
292 audio_frame_count *= 2; |
885 | 293 else |
316
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
294 audio_frame_count /= |
9aa23c6d396e
use the proper file framerate (specified by a float); account the pts
melanson
parents:
254
diff
changeset
|
295 (fourxm->tracks[fourxm->selected_track].bits / 8); |
740 | 296 fourxm->audio_pts += audio_frame_count; |
143 | 297 |
137 | 298 } else { |
299 url_fseek(pb, size, SEEK_CUR); | |
300 } | |
301 break; | |
302 | |
303 default: | |
304 url_fseek(pb, size, SEEK_CUR); | |
305 break; | |
306 } | |
307 } | |
308 return ret; | |
309 } | |
310 | |
311 static int fourxm_read_close(AVFormatContext *s) | |
312 { | |
2006 | 313 FourxmDemuxContext *fourxm = s->priv_data; |
137 | 314 |
315 av_free(fourxm->tracks); | |
316 | |
317 return 0; | |
318 } | |
319 | |
1169 | 320 AVInputFormat fourxm_demuxer = { |
137 | 321 "4xm", |
322 "4X Technologies format", | |
323 sizeof(FourxmDemuxContext), | |
324 fourxm_probe, | |
325 fourxm_read_header, | |
326 fourxm_read_packet, | |
327 fourxm_read_close, | |
328 }; |