comparison mmf.c @ 858:66cc656ea404 libavformat

Replace CONFIG_ENCODERS/CONFIG_DECODERS with CONFIG_MUXERS/CONFIG_DEMUXERS in libavformat to allow building (de)coders and (de)muxers independently at some point + support for this option in configure.
author diego
date Fri, 23 Sep 2005 00:25:41 +0000
parents acad29abfb70
children da1d5db0ce5c
comparison
equal deleted inserted replaced
857:26aaf3eed638 858:66cc656ea404
22 typedef struct { 22 typedef struct {
23 offset_t atrpos, atsqpos, awapos; 23 offset_t atrpos, atsqpos, awapos;
24 offset_t data_size; 24 offset_t data_size;
25 } MMFContext; 25 } MMFContext;
26 26
27 #ifdef CONFIG_ENCODERS 27 #ifdef CONFIG_MUXERS
28 static int mmf_rates[] = { 4000, 8000, 11025, 22050, 44100 }; 28 static int mmf_rates[] = { 4000, 8000, 11025, 22050, 44100 };
29 29
30 static int mmf_rate_code(int rate) 30 static int mmf_rate_code(int rate)
31 { 31 {
32 int i; 32 int i;
158 158
159 put_flush_packet(pb); 159 put_flush_packet(pb);
160 } 160 }
161 return 0; 161 return 0;
162 } 162 }
163 #endif //CONFIG_ENCODERS 163 #endif //CONFIG_MUXERS
164 164
165 static int mmf_probe(AVProbeData *p) 165 static int mmf_probe(AVProbeData *p)
166 { 166 {
167 /* check file header */ 167 /* check file header */
168 if (p->buf_size <= 32) 168 if (p->buf_size <= 32)
306 mmf_read_packet, 306 mmf_read_packet,
307 mmf_read_close, 307 mmf_read_close,
308 mmf_read_seek, 308 mmf_read_seek,
309 }; 309 };
310 310
311 #ifdef CONFIG_ENCODERS 311 #ifdef CONFIG_MUXERS
312 static AVOutputFormat mmf_oformat = { 312 static AVOutputFormat mmf_oformat = {
313 "mmf", 313 "mmf",
314 "mmf format", 314 "mmf format",
315 "application/vnd.smaf", 315 "application/vnd.smaf",
316 "mmf", 316 "mmf",
319 CODEC_ID_NONE, 319 CODEC_ID_NONE,
320 mmf_write_header, 320 mmf_write_header,
321 mmf_write_packet, 321 mmf_write_packet,
322 mmf_write_trailer, 322 mmf_write_trailer,
323 }; 323 };
324 #endif //CONFIG_ENCODERS 324 #endif //CONFIG_MUXERS
325 325
326 int ff_mmf_init(void) 326 int ff_mmf_init(void)
327 { 327 {
328 av_register_input_format(&mmf_iformat); 328 av_register_input_format(&mmf_iformat);
329 #ifdef CONFIG_ENCODERS 329 #ifdef CONFIG_MUXERS
330 av_register_output_format(&mmf_oformat); 330 av_register_output_format(&mmf_oformat);
331 #endif //CONFIG_ENCODERS 331 #endif //CONFIG_MUXERS
332 return 0; 332 return 0;
333 } 333 }
334 334