comparison mp3.c @ 1167:d89d7ef290da libavformat

give AVInput/OutputFormat structs consistent names
author mru
date Sun, 09 Jul 2006 23:40:53 +0000
parents 921c8af78310
children d18cc9a1fd02
comparison
equal deleted inserted replaced
1166:e89500dd9064 1167:d89d7ef290da
366 } 366 }
367 return 0; 367 return 0;
368 } 368 }
369 #endif //CONFIG_MUXERS 369 #endif //CONFIG_MUXERS
370 370
371 AVInputFormat mp3_iformat = { 371 AVInputFormat mp3_demuxer = {
372 "mp3", 372 "mp3",
373 "MPEG audio", 373 "MPEG audio",
374 0, 374 0,
375 mp3_read_probe, 375 mp3_read_probe,
376 mp3_read_header, 376 mp3_read_header,
378 mp3_read_close, 378 mp3_read_close,
379 .extensions = "mp2,mp3,m2a", /* XXX: use probe */ 379 .extensions = "mp2,mp3,m2a", /* XXX: use probe */
380 }; 380 };
381 381
382 #ifdef CONFIG_MUXERS 382 #ifdef CONFIG_MUXERS
383 AVOutputFormat mp2_oformat = { 383 AVOutputFormat mp2_muxer = {
384 "mp2", 384 "mp2",
385 "MPEG audio layer 2", 385 "MPEG audio layer 2",
386 "audio/x-mpeg", 386 "audio/x-mpeg",
387 #ifdef CONFIG_MP3LAME 387 #ifdef CONFIG_MP3LAME
388 "mp2,m2a", 388 "mp2,m2a",
396 mp3_write_packet, 396 mp3_write_packet,
397 mp3_write_trailer, 397 mp3_write_trailer,
398 }; 398 };
399 399
400 #ifdef CONFIG_MP3LAME 400 #ifdef CONFIG_MP3LAME
401 AVOutputFormat mp3_oformat = { 401 AVOutputFormat mp3_muxer = {
402 "mp3", 402 "mp3",
403 "MPEG audio layer 3", 403 "MPEG audio layer 3",
404 "audio/x-mpeg", 404 "audio/x-mpeg",
405 "mp3", 405 "mp3",
406 0, 406 0,
413 #endif 413 #endif
414 #endif //CONFIG_MUXERS 414 #endif //CONFIG_MUXERS
415 415
416 int mp3_init(void) 416 int mp3_init(void)
417 { 417 {
418 av_register_input_format(&mp3_iformat); 418 av_register_input_format(&mp3_demuxer);
419 #ifdef CONFIG_MUXERS 419 #ifdef CONFIG_MUXERS
420 av_register_output_format(&mp2_oformat); 420 av_register_output_format(&mp2_muxer);
421 #ifdef CONFIG_MP3LAME 421 #ifdef CONFIG_MP3LAME
422 av_register_output_format(&mp3_oformat); 422 av_register_output_format(&mp3_muxer);
423 #endif 423 #endif
424 #endif //CONFIG_MUXERS 424 #endif //CONFIG_MUXERS
425 return 0; 425 return 0;
426 } 426 }