Originally committed as revision 5707 to svn://svn.ffmpeg.org/ffmpeg/trunktags/v0.5
| @@ -104,7 +104,11 @@ show_help(){ | |||
| echo " --enable-decoder=NAME enables decoder NAME" | |||
| echo " --disable-encoders disables all encoders" | |||
| echo " --disable-decoders disables all decoders" | |||
| echo " --disable-muxer=NAME disables muxer NAME" | |||
| echo " --enable-muxer=NAME enables muxer NAME" | |||
| echo " --disable-muxers disables all muxers" | |||
| echo " --disable-demuxer=NAME disables demuxer NAME" | |||
| echo " --enable-demuxer=NAME enables demuxer NAME" | |||
| echo " --disable-demuxers disables all demuxers" | |||
| echo " --enable-parser=NAME enables parser NAME" | |||
| echo " --disable-parser=NAME disables parser NAME" | |||
| @@ -458,8 +462,6 @@ sunmlib="no" | |||
| pthreads="no" | |||
| gpl="no" | |||
| memalignhack="no" | |||
| muxers="yes" | |||
| demuxers="yes" | |||
| # OS specific | |||
| targetos=`uname -s` | |||
| @@ -662,6 +664,8 @@ done | |||
| CODEC_LIST=`grep 'register_avcodec(&[a-z]' $source_path/libavcodec/allcodecs.c | sed 's/.*&\(.*\)).*/\1/'` | |||
| PARSER_LIST=`grep 'av_register_codec_parser(&[a-z]' $source_path/libavcodec/allcodecs.c | sed 's/.*&\(.*\)).*/\1/'` | |||
| MUXER_LIST=`grep 'av_register_output_format(&[a-z]' $source_path/libavformat/allformats.c | sed 's/.*&\(.*\)).*/\1/'` | |||
| DEMUXER_LIST=`grep 'av_register_input_format(&[a-z]' $source_path/libavformat/allformats.c | sed 's/.*&\(.*\)).*/\1/'` | |||
| for opt do | |||
| case "$opt" in | |||
| @@ -819,9 +823,17 @@ for opt do | |||
| ;; | |||
| --disable-decoders) CODEC_LIST="`echo $CODEC_LIST | sed 's/[-_a-zA-Z0-9]*decoder//g'`" | |||
| ;; | |||
| --disable-muxers) muxers="no"; ffserver="no" | |||
| --enable-muxer=*) MUXER_LIST="$MUXER_LIST ${opt#*=}_muxer" | |||
| ;; | |||
| --disable-demuxers) demuxers="no" | |||
| --disable-muxer=*) MUXER_LIST="`echo $MUXER_LIST | sed -e \"s#${opt#*=}_muxer##\"`" | |||
| ;; | |||
| --disable-muxers) MUXER_LIST=""; ffserver="no" | |||
| ;; | |||
| --enable-demuxer=*) DEMUXER_LIST="$DEMUXER_LIST ${opt#*=}_demuxer" | |||
| ;; | |||
| --disable-demuxer=*) DEMUXER_LIST="`echo $DEMUXER_LIST | sed -e \"s#${opt#*=}_demuxer##\"`" | |||
| ;; | |||
| --disable-demuxers) DEMUXER_LIST="" | |||
| ;; | |||
| --enable-parser=*) PARSER_LIST="$PARSER_LIST ${opt#*=}_parser" | |||
| ;; | |||
| @@ -1763,13 +1775,13 @@ if echo "$CODEC_LIST" | grep -q decoder; then | |||
| fi | |||
| # muxers | |||
| if test "$muxers" = "yes" ; then | |||
| if echo "$MUXER_LIST" | grep -q muxer; then | |||
| echo "#define CONFIG_MUXERS 1" >> $TMPH | |||
| echo "CONFIG_MUXERS=yes" >> config.mak | |||
| fi | |||
| # demuxers | |||
| if test "$demuxers" = "yes" ; then | |||
| if echo "$DEMUXER_LIST" | grep -q demuxer; then | |||
| echo "#define CONFIG_DEMUXERS 1" >> $TMPH | |||
| echo "CONFIG_DEMUXERS=yes" >> config.mak | |||
| fi | |||
| @@ -2091,7 +2103,7 @@ if test "$amr_if2" = "yes" ; then | |||
| fi | |||
| for codec in $CODEC_LIST $PARSER_LIST; do | |||
| for codec in $CODEC_LIST $PARSER_LIST $DEMUXER_LIST $MUXER_LIST; do | |||
| echo "#define CONFIG_`echo $codec | tr a-z A-Z` 1" >> $TMPH | |||
| echo "CONFIG_`echo $codec | tr a-z A-Z`=yes" >> config.mak | |||
| done | |||
| @@ -318,7 +318,7 @@ static int fourxm_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat fourxm_demuxer = { | |||
| AVInputFormat fourxm_demuxer = { | |||
| "4xm", | |||
| "4X Technologies format", | |||
| sizeof(FourxmDemuxContext), | |||
| @@ -327,9 +327,3 @@ static AVInputFormat fourxm_demuxer = { | |||
| fourxm_read_packet, | |||
| fourxm_read_close, | |||
| }; | |||
| int fourxm_init(void) | |||
| { | |||
| av_register_input_format(&fourxm_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -13,51 +13,148 @@ CPPOBJS= | |||
| HEADERS = avformat.h avio.h rtp.h rtsp.h rtspcodes.h | |||
| # demuxers | |||
| OBJS+=mpeg.o mpegts.o mpegtsenc.o ffm.o crc.o img.o img2.o raw.o rm.o \ | |||
| avienc.o avidec.o wav.o mmf.o swf.o au.o gif.o mov.o mpjpeg.o dv.o \ | |||
| yuv4mpeg.o 4xm.o flvdec.o psxstr.o idroq.o ipmovie.o \ | |||
| nut.o wc3movie.o mp3.o westwood.o segafilm.o idcin.o flic.o \ | |||
| sierravmd.o matroska.o sol.o electronicarts.o nsvdec.o asf.o \ | |||
| ogg2.o oggparsevorbis.o oggparsetheora.o oggparseflac.o daud.o aiff.o \ | |||
| voc.o tta.o mm.o avs.o smacker.o nuv.o gxf.o oggparseogm.o | |||
| # muxers | |||
| ifeq ($(CONFIG_MUXERS),yes) | |||
| OBJS+= flvenc.o movenc.o asf-enc.o adtsenc.o | |||
| endif | |||
| ifeq ($(AMR),yes) | |||
| OBJS+= amr.o | |||
| endif | |||
| # muxers/demuxers | |||
| OBJS-$(CONFIG_FOURXM_DEMUXER) += 4xm.o | |||
| OBJS-$(CONFIG_ADTS_MUXER) += adtsenc.o | |||
| OBJS-$(CONFIG_AIFF_DEMUXER) += aiff.o | |||
| OBJS-$(CONFIG_AIFF_MUXER) += aiff.o | |||
| OBJS-$(CONFIG_AMR_DEMUXER) += amr.o | |||
| OBJS-$(CONFIG_AMR_MUXER) += amr.o | |||
| OBJS-$(CONFIG_ASF_DEMUXER) += asf.o | |||
| OBJS-$(CONFIG_ASF_MUXER) += asf-enc.o | |||
| OBJS-$(CONFIG_ASF_STREAM_MUXER) += asf-enc.o | |||
| OBJS-$(CONFIG_AU_DEMUXER) += au.o | |||
| OBJS-$(CONFIG_AU_MUXER) += au.o | |||
| OBJS-$(CONFIG_AVI_DEMUXER) += avidec.o | |||
| OBJS-$(CONFIG_AVI_MUXER) += avienc.o | |||
| OBJS-$(CONFIG_AVS_DEMUXER) += avs.o | |||
| OBJS-$(CONFIG_CRC_MUXER) += crc.o | |||
| OBJS-$(CONFIG_FRAMECRC_MUXER) += crc.o | |||
| OBJS-$(CONFIG_DAUD_DEMUXER) += daud.o | |||
| OBJS-$(CONFIG_DV_DEMUXER) += dv.o | |||
| OBJS-$(CONFIG_DV_MUXER) += dv.o | |||
| OBJS-$(CONFIG_EA_DEMUXER) += electronicarts.o | |||
| OBJS-$(CONFIG_FFM_DEMUXER) += ffm.o | |||
| OBJS-$(CONFIG_FFM_MUXER) += ffm.o | |||
| OBJS-$(CONFIG_FLIC_DEMUXER) += flic.o | |||
| OBJS-$(CONFIG_FLV_DEMUXER) += flvdec.o | |||
| OBJS-$(CONFIG_FLV_MUXER) += flvenc.o | |||
| OBJS-$(CONFIG_GIF_MUXER) += gif.o | |||
| OBJS-$(CONFIG_GIF_DEMUXER) += gifdec.o | |||
| OBJS-$(CONFIG_GXF_DEMUXER) += gxf.o | |||
| OBJS-$(CONFIG_IDCIN_DEMUXER) += idcin.o | |||
| OBJS-$(CONFIG_ROQ_DEMUXER) += idroq.o | |||
| OBJS-$(CONFIG_IMAGE2_DEMUXER) += img2.o | |||
| OBJS-$(CONFIG_IMAGE2PIPE_DEMUXER) += img2.o | |||
| OBJS-$(CONFIG_IMAGE2_MUXER) += img2.o | |||
| OBJS-$(CONFIG_IMAGE2PIPE_MUXER) += img2.o | |||
| OBJS-$(CONFIG_IMAGE_DEMUXER) += img.o | |||
| OBJS-$(CONFIG_IMAGEPIPE_DEMUXER) += img.o | |||
| OBJS-$(CONFIG_IMAGE_MUXER) += img.o | |||
| OBJS-$(CONFIG_IMAGEPIPE_MUXER) += img.o | |||
| OBJS-$(CONFIG_IPMOVIE_DEMUXER) += ipmovie.o | |||
| OBJS-$(CONFIG_MATROSKA_DEMUXER) += matroska.o | |||
| OBJS-$(CONFIG_MM_DEMUXER) += mm.o | |||
| OBJS-$(CONFIG_MMF_DEMUXER) += mmf.o | |||
| OBJS-$(CONFIG_MMF_MUXER) += mmf.o | |||
| OBJS-$(CONFIG_MOV_DEMUXER) += mov.o | |||
| OBJS-$(CONFIG_MOV_MUXER) += movenc.o | |||
| OBJS-$(CONFIG_TGP_MUXER) += movenc.o | |||
| OBJS-$(CONFIG_MP4_MUXER) += movenc.o | |||
| OBJS-$(CONFIG_PSP_MUXER) += movenc.o | |||
| OBJS-$(CONFIG_TG2_MUXER) += movenc.o | |||
| OBJS-$(CONFIG_MP3_DEMUXER) += mp3.o | |||
| OBJS-$(CONFIG_MP2_MUXER) += mp3.o | |||
| OBJS-$(CONFIG_MP3_MUXER) += mp3.o | |||
| OBJS-$(CONFIG_MPEG1SYSTEM_MUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEG1VCD_MUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEG2VOB_MUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEG2SVCD_MUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEG2DVD_MUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEGPS_DEMUXER) += mpeg.o | |||
| OBJS-$(CONFIG_MPEGTS_DEMUXER) += mpegts.o | |||
| OBJS-$(CONFIG_MPEGTS_MUXER) += mpegtsenc.o | |||
| OBJS-$(CONFIG_MPJPEG_MUXER) += mpjpeg.o | |||
| OBJS-$(CONFIG_NSV_DEMUXER) += nsvdec.o | |||
| OBJS-$(CONFIG_NUT_DEMUXER) += nut.o | |||
| OBJS-$(CONFIG_NUT_MUXER) += nut.o | |||
| OBJS-$(CONFIG_NUV_DEMUXER) += nuv.o | |||
| OBJS-$(CONFIG_OGG_DEMUXER) += ogg2.o \ | |||
| oggparsevorbis.o \ | |||
| oggparsetheora.o \ | |||
| oggparseflac.o \ | |||
| oggparseogm.o | |||
| OBJS-$(CONFIG_STR_DEMUXER) += psxstr.o | |||
| OBJS-$(CONFIG_SHORTEN_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_FLAC_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_FLAC_MUXER) += raw.o | |||
| OBJS-$(CONFIG_AC3_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_AC3_MUXER) += raw.o | |||
| OBJS-$(CONFIG_DTS_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_AAC_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_H261_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_H261_MUXER) += raw.o | |||
| OBJS-$(CONFIG_H263_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_H263_MUXER) += raw.o | |||
| OBJS-$(CONFIG_M4V_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_M4V_MUXER) += raw.o | |||
| OBJS-$(CONFIG_H264_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_H264_MUXER) += raw.o | |||
| OBJS-$(CONFIG_MPEGVIDEO_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_MPEG1VIDEO_MUXER) += raw.o | |||
| OBJS-$(CONFIG_MPEG2VIDEO_MUXER) += raw.o | |||
| OBJS-$(CONFIG_MJPEG_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_INGENIENT_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_MJPEG_MUXER) += raw.o | |||
| OBJS-$(CONFIG_RAWVIDEO_DEMUXER) += raw.o | |||
| OBJS-$(CONFIG_RAWVIDEO_MUXER) += raw.o | |||
| OBJS-$(CONFIG_NULL_MUXER) += raw.o | |||
| OBJS-$(CONFIG_RM_DEMUXER) += rm.o | |||
| OBJS-$(CONFIG_RM_MUXER) += rm.o | |||
| OBJS-$(CONFIG_SEGAFILM_DEMUXER) += segafilm.o | |||
| OBJS-$(CONFIG_VMD_DEMUXER) += sierravmd.o | |||
| OBJS-$(CONFIG_SMACKER_DEMUXER) += smacker.o | |||
| OBJS-$(CONFIG_SOL_DEMUXER) += sol.o | |||
| OBJS-$(CONFIG_SWF_DEMUXER) += swf.o | |||
| OBJS-$(CONFIG_SWF_MUXER) += swf.o | |||
| OBJS-$(CONFIG_TTA_DEMUXER) += tta.o | |||
| OBJS-$(CONFIG_VOC_DEMUXER) += voc.o | |||
| OBJS-$(CONFIG_VOC_MUXER) += voc.o | |||
| OBJS-$(CONFIG_WAV_DEMUXER) += wav.o | |||
| OBJS-$(CONFIG_WAV_MUXER) += wav.o | |||
| OBJS-$(CONFIG_WC3_DEMUXER) += wc3movie.o | |||
| OBJS-$(CONFIG_WSAUD_DEMUXER) += westwood.o | |||
| OBJS-$(CONFIG_WSVQA_DEMUXER) += westwood.o | |||
| OBJS-$(CONFIG_YUV4MPEGPIPE_MUXER) += yuv4mpeg.o | |||
| OBJS-$(CONFIG_YUV4MPEGPIPE_DEMUXER) += yuv4mpeg.o | |||
| # image formats | |||
| OBJS+= pnm.o yuv.o png.o jpeg.o gifdec.o sgi.o | |||
| OBJS+= framehook.o | |||
| ifeq ($(CONFIG_VIDEO4LINUX),yes) | |||
| OBJS+= grab.o | |||
| OBJS-$(CONFIG_VIDEO_GRAB_DEVICE_DEMUXER) += grab.o | |||
| endif | |||
| ifeq ($(CONFIG_VIDEO4LINUX2),yes) | |||
| OBJS+= v4l2.o | |||
| OBJS-$(CONFIG_V4L2_DEMUXER) += v4l2.o | |||
| endif | |||
| ifeq ($(CONFIG_BKTR),yes) | |||
| OBJS+= grab_bktr.o | |||
| OBJS-$(CONFIG_VIDEO_GRAB_DEVICE_DEMUXER) += grab_bktr.o | |||
| endif | |||
| ifeq ($(CONFIG_DV1394),yes) | |||
| OBJS+= dv1394.o | |||
| OBJS-$(CONFIG_DV1394_DEMUXER) += dv1394.o | |||
| endif | |||
| ifeq ($(CONFIG_DC1394),yes) | |||
| OBJS+= dc1394.o | |||
| OBJS-$(CONFIG_DC1394_DEMUXER) += dc1394.o | |||
| endif | |||
| ifeq ($(CONFIG_AUDIO_OSS),yes) | |||
| OBJS+= audio.o | |||
| OBJS-$(CONFIG_AUDIO_DEMUXER) += audio.o | |||
| OBJS-$(CONFIG_AUDIO_MUXER) += audio.o | |||
| endif | |||
| EXTRALIBS := -L../libavutil -lavutil$(BUILDSUF) \ | |||
| @@ -82,9 +179,11 @@ endif | |||
| endif | |||
| ifeq ($(CONFIG_LIBOGG),yes) | |||
| OBJS+= ogg.o | |||
| OBJS-$(CONFIG_OGG_MUXER) += ogg.o | |||
| endif | |||
| OBJS += $(OBJS-yes) | |||
| NAME=avformat | |||
| ifeq ($(BUILD_SHARED),yes) | |||
| LIBVERSION=$(LAVFVERSION) | |||
| @@ -107,7 +107,7 @@ static int adts_write_packet(AVFormatContext *s, AVPacket *pkt) | |||
| return 0; | |||
| } | |||
| static AVOutputFormat adts_muxer = { | |||
| AVOutputFormat adts_muxer = { | |||
| "adts", | |||
| "ADTS AAC", | |||
| "audio/aac", | |||
| @@ -119,9 +119,3 @@ static AVOutputFormat adts_muxer = { | |||
| adts_write_packet, | |||
| adts_write_trailer, | |||
| }; | |||
| int ff_adts_init(void) | |||
| { | |||
| av_register_output_format(&adts_muxer); | |||
| return 0; | |||
| } | |||
| @@ -428,8 +428,8 @@ static int aiff_read_seek(AVFormatContext *s, | |||
| return pcm_read_seek(s, stream_index, timestamp, flags); | |||
| } | |||
| static AVInputFormat aiff_demuxer = { | |||
| #ifdef CONFIG_AIFF_DEMUXER | |||
| AVInputFormat aiff_demuxer = { | |||
| "aiff", | |||
| "Audio IFF", | |||
| 0, | |||
| @@ -439,9 +439,10 @@ static AVInputFormat aiff_demuxer = { | |||
| aiff_read_close, | |||
| aiff_read_seek, | |||
| }; | |||
| #endif | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat aiff_muxer = { | |||
| #ifdef CONFIG_AIFF_DEMUXER | |||
| AVOutputFormat aiff_muxer = { | |||
| "aiff", | |||
| "Audio IFF", | |||
| "audio/aiff", | |||
| @@ -453,14 +454,4 @@ static AVOutputFormat aiff_muxer = { | |||
| aiff_write_packet, | |||
| aiff_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int ff_aiff_init(void) | |||
| { | |||
| av_register_input_format(&aiff_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&aiff_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -36,95 +36,381 @@ void av_register_all(void) | |||
| avcodec_init(); | |||
| avcodec_register_all(); | |||
| mpegps_init(); | |||
| mpegts_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| crc_init(); | |||
| img_init(); | |||
| img2_init(); | |||
| #endif //CONFIG_MUXERS | |||
| raw_init(); | |||
| mp3_init(); | |||
| rm_init(); | |||
| asf_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| avienc_init(); | |||
| #endif //CONFIG_MUXERS | |||
| avidec_init(); | |||
| ff_wav_init(); | |||
| ff_mmf_init(); | |||
| swf_init(); | |||
| au_init(); | |||
| ff_aiff_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| ff_adts_init(); | |||
| gif_init(); | |||
| #endif //CONFIG_MUXERS | |||
| mov_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| movenc_init(); | |||
| jpeg_init(); | |||
| #endif //CONFIG_MUXERS | |||
| ff_dv_init(); | |||
| fourxm_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| flvenc_init(); | |||
| #endif //CONFIG_MUXERS | |||
| flvdec_init(); | |||
| str_init(); | |||
| roq_init(); | |||
| ipmovie_init(); | |||
| wc3_init(); | |||
| westwood_init(); | |||
| film_init(); | |||
| idcin_init(); | |||
| flic_init(); | |||
| vmd_init(); | |||
| mm_init(); | |||
| smacker_init(); | |||
| #if defined(AMR_NB) || defined(AMR_NB_FIXED) || defined(AMR_WB) | |||
| amr_init(); | |||
| #ifdef CONFIG_FOURXM_DEMUXER | |||
| av_register_input_format(&fourxm_demuxer); | |||
| #endif | |||
| yuv4mpeg_init(); | |||
| ogg_init(); | |||
| #ifdef CONFIG_LIBOGG | |||
| libogg_init(); | |||
| #ifdef CONFIG_ADTS_MUXER | |||
| av_register_output_format(&adts_muxer); | |||
| #endif | |||
| ffm_init(); | |||
| #if defined(CONFIG_VIDEO4LINUX2) | |||
| v4l2_init(); | |||
| #ifdef CONFIG_AIFF_DEMUXER | |||
| av_register_input_format(&aiff_demuxer); | |||
| #endif | |||
| #if defined(CONFIG_VIDEO4LINUX) || defined(CONFIG_BKTR) | |||
| video_grab_init(); | |||
| #ifdef CONFIG_AIFF_MUXER | |||
| av_register_output_format(&aiff_muxer); | |||
| #endif | |||
| #ifdef CONFIG_AMR_DEMUXER | |||
| av_register_input_format(&amr_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_AMR_MUXER | |||
| av_register_output_format(&amr_muxer); | |||
| #endif | |||
| #ifdef CONFIG_ASF_DEMUXER | |||
| av_register_input_format(&asf_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_ASF_MUXER | |||
| av_register_output_format(&asf_muxer); | |||
| #endif | |||
| #ifdef CONFIG_ASF_STREAM_MUXER | |||
| av_register_output_format(&asf_stream_muxer); | |||
| #endif | |||
| #ifdef CONFIG_AU_DEMUXER | |||
| av_register_input_format(&au_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_AU_MUXER | |||
| av_register_output_format(&au_muxer); | |||
| #endif | |||
| #if defined(CONFIG_AUDIO_OSS) || defined(CONFIG_AUDIO_BEOS) | |||
| audio_init(); | |||
| #ifdef CONFIG_AUDIO_DEMUXER | |||
| av_register_input_format(&audio_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_DV1394 | |||
| dv1394_init(); | |||
| #ifdef CONFIG_AUDIO_MUXER | |||
| av_register_output_format(&audio_muxer); | |||
| #endif | |||
| #endif /* CONFIG_AUDIO_OSS || CONFIG_AUDIO_BEOS */ | |||
| #ifdef CONFIG_AVI_DEMUXER | |||
| av_register_input_format(&avi_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_AVI_MUXER | |||
| av_register_output_format(&avi_muxer); | |||
| #endif | |||
| #ifdef CONFIG_AVS_DEMUXER | |||
| av_register_input_format(&avs_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_CRC_MUXER | |||
| av_register_output_format(&crc_muxer); | |||
| #endif | |||
| #ifdef CONFIG_FRAMECRC_MUXER | |||
| av_register_output_format(&framecrc_muxer); | |||
| #endif | |||
| #ifdef CONFIG_DAUD_DEMUXER | |||
| av_register_input_format(&daud_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_DC1394 | |||
| dc1394_init(); | |||
| #ifdef CONFIG_DC1394_DEMUXER | |||
| av_register_input_format(&dc1394_demuxer); | |||
| #endif | |||
| #endif /* CONFIG_DC1394 */ | |||
| #ifdef CONFIG_DV1394 | |||
| #ifdef CONFIG_DV1394_DEMUXER | |||
| av_register_input_format(&dv1394_demuxer); | |||
| #endif | |||
| #endif /* CONFIG_DV1394 */ | |||
| #ifdef CONFIG_DV_DEMUXER | |||
| av_register_input_format(&dv_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_DV_MUXER | |||
| av_register_output_format(&dv_muxer); | |||
| #endif | |||
| #ifdef CONFIG_EA_DEMUXER | |||
| av_register_input_format(&ea_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FFM_DEMUXER | |||
| av_register_input_format(&ffm_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FFM_MUXER | |||
| av_register_output_format(&ffm_muxer); | |||
| #endif | |||
| #ifdef CONFIG_FLIC_DEMUXER | |||
| av_register_input_format(&flic_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FLV_DEMUXER | |||
| av_register_input_format(&flv_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FLV_MUXER | |||
| av_register_output_format(&flv_muxer); | |||
| #endif | |||
| #ifdef CONFIG_GIF_MUXER | |||
| av_register_output_format(&gif_muxer); | |||
| #endif | |||
| #ifdef CONFIG_GIF_DEMUXER | |||
| av_register_input_format(&gif_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_GXF_DEMUXER | |||
| av_register_input_format(&gxf_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IDCIN_DEMUXER | |||
| av_register_input_format(&idcin_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_ROQ_DEMUXER | |||
| av_register_input_format(&roq_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2_DEMUXER | |||
| av_register_input_format(&image2_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2PIPE_DEMUXER | |||
| av_register_input_format(&image2pipe_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2_MUXER | |||
| av_register_output_format(&image2_muxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2PIPE_MUXER | |||
| av_register_output_format(&image2pipe_muxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE_DEMUXER | |||
| av_register_input_format(&image_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGEPIPE_DEMUXER | |||
| av_register_input_format(&imagepipe_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGE_MUXER | |||
| av_register_output_format(&image_muxer); | |||
| #endif | |||
| #ifdef CONFIG_IMAGEPIPE_MUXER | |||
| av_register_output_format(&imagepipe_muxer); | |||
| #endif | |||
| #ifdef CONFIG_IPMOVIE_DEMUXER | |||
| av_register_input_format(&ipmovie_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MATROSKA_DEMUXER | |||
| av_register_input_format(&matroska_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MM_DEMUXER | |||
| av_register_input_format(&mm_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MMF_DEMUXER | |||
| av_register_input_format(&mmf_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MMF_MUXER | |||
| av_register_output_format(&mmf_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MOV_DEMUXER | |||
| av_register_input_format(&mov_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MOV_MUXER | |||
| av_register_output_format(&mov_muxer); | |||
| #endif | |||
| #ifdef CONFIG_TGP_MUXER | |||
| av_register_output_format(&tgp_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MP4_MUXER | |||
| av_register_output_format(&mp4_muxer); | |||
| #endif | |||
| #ifdef CONFIG_PSP_MUXER | |||
| av_register_output_format(&psp_muxer); | |||
| #endif | |||
| #ifdef CONFIG_TG2_MUXER | |||
| av_register_output_format(&tg2_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MP3_DEMUXER | |||
| av_register_input_format(&mp3_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MP2_MUXER | |||
| av_register_output_format(&mp2_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MP3_MUXER | |||
| av_register_output_format(&mp3_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG1SYSTEM_MUXER | |||
| av_register_output_format(&mpeg1system_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG1VCD_MUXER | |||
| av_register_output_format(&mpeg1vcd_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG2VOB_MUXER | |||
| av_register_output_format(&mpeg2vob_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG2SVCD_MUXER | |||
| av_register_output_format(&mpeg2svcd_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG2DVD_MUXER | |||
| av_register_output_format(&mpeg2dvd_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEGPS_DEMUXER | |||
| av_register_input_format(&mpegps_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEGTS_DEMUXER | |||
| av_register_input_format(&mpegts_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEGTS_MUXER | |||
| av_register_output_format(&mpegts_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPJPEG_MUXER | |||
| av_register_output_format(&mpjpeg_muxer); | |||
| #endif | |||
| #ifdef CONFIG_NSV_DEMUXER | |||
| av_register_input_format(&nsv_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_NUT_DEMUXER | |||
| av_register_input_format(&nut_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_NUT_MUXER | |||
| av_register_output_format(&nut_muxer); | |||
| #endif | |||
| #ifdef CONFIG_NUV_DEMUXER | |||
| av_register_input_format(&nuv_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_OGG_DEMUXER | |||
| av_register_input_format(&ogg_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_LIBOGG | |||
| #ifdef CONFIG_OGG_MUXER | |||
| av_register_output_format(&ogg_muxer); | |||
| #endif | |||
| #endif /* CONFIG_LIBOGG */ | |||
| #ifdef CONFIG_STR_DEMUXER | |||
| av_register_input_format(&str_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SHORTEN_DEMUXER | |||
| av_register_input_format(&shorten_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FLAC_DEMUXER | |||
| av_register_input_format(&flac_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_FLAC_MUXER | |||
| av_register_output_format(&flac_muxer); | |||
| #endif | |||
| #ifdef CONFIG_AC3_DEMUXER | |||
| av_register_input_format(&ac3_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_AC3_MUXER | |||
| av_register_output_format(&ac3_muxer); | |||
| #endif | |||
| #ifdef CONFIG_DTS_DEMUXER | |||
| av_register_input_format(&dts_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_AAC_DEMUXER | |||
| av_register_input_format(&aac_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_H261_DEMUXER | |||
| av_register_input_format(&h261_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_H261_MUXER | |||
| av_register_output_format(&h261_muxer); | |||
| #endif | |||
| #ifdef CONFIG_H263_DEMUXER | |||
| av_register_input_format(&h263_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_H263_MUXER | |||
| av_register_output_format(&h263_muxer); | |||
| #endif | |||
| #ifdef CONFIG_M4V_DEMUXER | |||
| av_register_input_format(&m4v_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_M4V_MUXER | |||
| av_register_output_format(&m4v_muxer); | |||
| #endif | |||
| #ifdef CONFIG_H264_DEMUXER | |||
| av_register_input_format(&h264_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_H264_MUXER | |||
| av_register_output_format(&h264_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEGVIDEO_DEMUXER | |||
| av_register_input_format(&mpegvideo_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG1VIDEO_MUXER | |||
| av_register_output_format(&mpeg1video_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MPEG2VIDEO_MUXER | |||
| av_register_output_format(&mpeg2video_muxer); | |||
| #endif | |||
| #ifdef CONFIG_MJPEG_DEMUXER | |||
| av_register_input_format(&mjpeg_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_INGENIENT_DEMUXER | |||
| av_register_input_format(&ingenient_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_MJPEG_MUXER | |||
| av_register_output_format(&mjpeg_muxer); | |||
| #endif | |||
| #ifdef CONFIG_RAWVIDEO_DEMUXER | |||
| av_register_input_format(&rawvideo_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_RAWVIDEO_MUXER | |||
| av_register_output_format(&rawvideo_muxer); | |||
| #endif | |||
| #ifdef CONFIG_NULL_MUXER | |||
| av_register_output_format(&null_muxer); | |||
| #endif | |||
| #ifdef CONFIG_RM_DEMUXER | |||
| av_register_input_format(&rm_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_RM_MUXER | |||
| av_register_output_format(&rm_muxer); | |||
| #endif | |||
| #ifdef CONFIG_NETWORK | |||
| #ifdef CONFIG_RTP_MUXER | |||
| av_register_output_format(&rtp_muxer); | |||
| #endif | |||
| #ifdef CONFIG_RTSP_DEMUXER | |||
| av_register_input_format(&rtsp_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SDP_DEMUXER | |||
| av_register_input_format(&sdp_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_REDIR_DEMUXER | |||
| av_register_input_format(&redir_demuxer); | |||
| #endif | |||
| #endif /* CONFIG_NETWORK */ | |||
| #ifdef CONFIG_SEGAFILM_DEMUXER | |||
| av_register_input_format(&segafilm_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_VMD_DEMUXER | |||
| av_register_input_format(&vmd_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SMACKER_DEMUXER | |||
| av_register_input_format(&smacker_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SOL_DEMUXER | |||
| av_register_input_format(&sol_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SWF_DEMUXER | |||
| av_register_input_format(&swf_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_SWF_MUXER | |||
| av_register_output_format(&swf_muxer); | |||
| #endif | |||
| #ifdef CONFIG_TTA_DEMUXER | |||
| av_register_input_format(&tta_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_VIDEO4LINUX2 | |||
| #ifdef CONFIG_V4L2_DEMUXER | |||
| av_register_input_format(&v4l2_demuxer); | |||
| #endif | |||
| #endif /* CONFIG_VIDEO4LINUX2 */ | |||
| #if defined(CONFIG_VIDEO4LINUX) || defined(CONFIG_BKTR) | |||
| #ifdef CONFIG_VIDEO_GRAB_DEVICE_DEMUXER | |||
| av_register_input_format(&video_grab_device_demuxer); | |||
| #endif | |||
| #endif /* CONFIG_VIDEO4LINUX || CONFIG_BKTR */ | |||
| #ifdef CONFIG_VOC_DEMUXER | |||
| av_register_input_format(&voc_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_VOC_MUXER | |||
| av_register_output_format(&voc_muxer); | |||
| #endif | |||
| #ifdef CONFIG_WAV_DEMUXER | |||
| av_register_input_format(&wav_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_WAV_MUXER | |||
| av_register_output_format(&wav_muxer); | |||
| #endif | |||
| #ifdef CONFIG_WC3_DEMUXER | |||
| av_register_input_format(&wc3_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_WSAUD_DEMUXER | |||
| av_register_input_format(&wsaud_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_WSVQA_DEMUXER | |||
| av_register_input_format(&wsvqa_demuxer); | |||
| #endif | |||
| #ifdef CONFIG_YUV4MPEGPIPE_MUXER | |||
| av_register_output_format(&yuv4mpegpipe_muxer); | |||
| #endif | |||
| #ifdef CONFIG_YUV4MPEGPIPE_DEMUXER | |||
| av_register_input_format(&yuv4mpegpipe_demuxer); | |||
| #endif | |||
| nut_init(); | |||
| matroska_init(); | |||
| sol_init(); | |||
| ea_init(); | |||
| nsvdec_init(); | |||
| daud_init(); | |||
| voc_init(); | |||
| tta_init(); | |||
| avs_init(); | |||
| nuv_init(); | |||
| gxf_init(); | |||
| #ifdef CONFIG_MUXERS | |||
| /* image formats */ | |||
| #if 0 | |||
| av_register_image_format(&pnm_image_format); | |||
| @@ -141,15 +427,12 @@ void av_register_all(void) | |||
| #endif | |||
| av_register_image_format(&gif_image_format); | |||
| // av_register_image_format(&sgi_image_format); heap corruption, dont enable | |||
| #endif //CONFIG_MUXERS | |||
| #ifdef CONFIG_PROTOCOLS | |||
| /* file protocols */ | |||
| register_protocol(&file_protocol); | |||
| register_protocol(&pipe_protocol); | |||
| #ifdef CONFIG_NETWORK | |||
| rtsp_init(); | |||
| rtp_init(); | |||
| register_protocol(&udp_protocol); | |||
| register_protocol(&rtp_protocol); | |||
| register_protocol(&tcp_protocol); | |||
| @@ -1,173 +1,135 @@ | |||
| #ifndef ALLFORMATS_H | |||
| #define ALLFORMATS_H | |||
| /* mpeg.c */ | |||
| extern AVInputFormat fourxm_demuxer; | |||
| extern AVOutputFormat adts_muxer; | |||
| extern AVInputFormat aiff_demuxer; | |||
| extern AVOutputFormat aiff_muxer; | |||
| extern AVInputFormat amr_demuxer; | |||
| extern AVOutputFormat amr_muxer; | |||
| extern AVInputFormat asf_demuxer; | |||
| extern AVOutputFormat asf_muxer; | |||
| extern AVOutputFormat asf_stream_muxer; | |||
| extern AVInputFormat au_demuxer; | |||
| extern AVOutputFormat au_muxer; | |||
| extern AVInputFormat audio_demuxer; | |||
| extern AVOutputFormat audio_muxer; | |||
| extern AVInputFormat avi_demuxer; | |||
| extern AVOutputFormat avi_muxer; | |||
| extern AVInputFormat avs_demuxer; | |||
| extern AVOutputFormat crc_muxer; | |||
| extern AVOutputFormat framecrc_muxer; | |||
| extern AVInputFormat daud_demuxer; | |||
| extern AVInputFormat dc1394_demuxer; | |||
| extern AVInputFormat dv1394_demuxer; | |||
| extern AVInputFormat dv_demuxer; | |||
| extern AVOutputFormat dv_muxer; | |||
| extern AVInputFormat ea_demuxer; | |||
| extern AVInputFormat ffm_demuxer; | |||
| extern AVOutputFormat ffm_muxer; | |||
| extern AVInputFormat flic_demuxer; | |||
| extern AVInputFormat flv_demuxer; | |||
| extern AVOutputFormat flv_muxer; | |||
| extern AVOutputFormat gif_muxer; | |||
| extern AVInputFormat gif_demuxer; | |||
| extern AVInputFormat video_grab_device_demuxer; | |||
| extern AVInputFormat video_grab_device_demuxer; | |||
| extern AVInputFormat gxf_demuxer; | |||
| extern AVInputFormat idcin_demuxer; | |||
| extern AVInputFormat roq_demuxer; | |||
| extern AVInputFormat image2_demuxer; | |||
| extern AVInputFormat image2pipe_demuxer; | |||
| extern AVOutputFormat image2_muxer; | |||
| extern AVOutputFormat image2pipe_muxer; | |||
| extern AVInputFormat image_demuxer; | |||
| extern AVInputFormat imagepipe_demuxer; | |||
| extern AVOutputFormat image_muxer; | |||
| extern AVOutputFormat imagepipe_muxer; | |||
| extern AVInputFormat ipmovie_demuxer; | |||
| extern AVInputFormat matroska_demuxer; | |||
| extern AVInputFormat mm_demuxer; | |||
| extern AVInputFormat mmf_demuxer; | |||
| extern AVOutputFormat mmf_muxer; | |||
| extern AVInputFormat mov_demuxer; | |||
| extern AVOutputFormat mov_muxer; | |||
| extern AVOutputFormat tgp_muxer; | |||
| extern AVOutputFormat mp4_muxer; | |||
| extern AVOutputFormat psp_muxer; | |||
| extern AVOutputFormat tg2_muxer; | |||
| extern AVInputFormat mp3_demuxer; | |||
| extern AVOutputFormat mp2_muxer; | |||
| extern AVOutputFormat mp3_muxer; | |||
| extern AVOutputFormat mpeg1system_muxer; | |||
| extern AVOutputFormat mpeg1vcd_muxer; | |||
| extern AVOutputFormat mpeg2vob_muxer; | |||
| extern AVOutputFormat mpeg2svcd_muxer; | |||
| extern AVOutputFormat mpeg2dvd_muxer; | |||
| extern AVInputFormat mpegps_demuxer; | |||
| int mpegps_init(void); | |||
| /* mpegts.c */ | |||
| extern AVInputFormat mpegts_demuxer; | |||
| int mpegts_init(void); | |||
| /* rm.c */ | |||
| int rm_init(void); | |||
| /* crc.c */ | |||
| int crc_init(void); | |||
| /* img.c */ | |||
| int img_init(void); | |||
| /* img2.c */ | |||
| int img2_init(void); | |||
| /* asf.c */ | |||
| int asf_init(void); | |||
| /* avienc.c */ | |||
| int avienc_init(void); | |||
| /* avidec.c */ | |||
| int avidec_init(void); | |||
| /* swf.c */ | |||
| int swf_init(void); | |||
| /* mov.c */ | |||
| int mov_init(void); | |||
| /* movenc.c */ | |||
| int movenc_init(void); | |||
| /* flvenc.c */ | |||
| int flvenc_init(void); | |||
| /* flvdec.c */ | |||
| int flvdec_init(void); | |||
| /* jpeg.c */ | |||
| int jpeg_init(void); | |||
| /* gif.c */ | |||
| int gif_init(void); | |||
| /* au.c */ | |||
| int au_init(void); | |||
| /* amr.c */ | |||
| int amr_init(void); | |||
| /* wav.c */ | |||
| int ff_wav_init(void); | |||
| /* mmf.c */ | |||
| int ff_mmf_init(void); | |||
| extern AVOutputFormat mpegts_muxer; | |||
| extern AVOutputFormat mpjpeg_muxer; | |||
| extern AVInputFormat nsv_demuxer; | |||
| extern AVInputFormat nut_demuxer; | |||
| extern AVOutputFormat nut_muxer; | |||
| extern AVInputFormat nuv_demuxer; | |||
| extern AVInputFormat ogg_demuxer; | |||
| extern AVOutputFormat ogg_muxer; | |||
| extern AVInputFormat str_demuxer; | |||
| extern AVInputFormat shorten_demuxer; | |||
| extern AVInputFormat flac_demuxer; | |||
| extern AVOutputFormat flac_muxer; | |||
| extern AVInputFormat ac3_demuxer; | |||
| extern AVOutputFormat ac3_muxer; | |||
| extern AVInputFormat dts_demuxer; | |||
| extern AVInputFormat aac_demuxer; | |||
| extern AVInputFormat h261_demuxer; | |||
| extern AVOutputFormat h261_muxer; | |||
| extern AVInputFormat h263_demuxer; | |||
| extern AVOutputFormat h263_muxer; | |||
| extern AVInputFormat m4v_demuxer; | |||
| extern AVOutputFormat m4v_muxer; | |||
| extern AVInputFormat h264_demuxer; | |||
| extern AVOutputFormat h264_muxer; | |||
| extern AVInputFormat mpegvideo_demuxer; | |||
| extern AVOutputFormat mpeg1video_muxer; | |||
| extern AVOutputFormat mpeg2video_muxer; | |||
| extern AVInputFormat mjpeg_demuxer; | |||
| extern AVInputFormat ingenient_demuxer; | |||
| extern AVOutputFormat mjpeg_muxer; | |||
| extern AVInputFormat rawvideo_demuxer; | |||
| extern AVOutputFormat rawvideo_muxer; | |||
| extern AVOutputFormat null_muxer; | |||
| extern AVInputFormat rm_demuxer; | |||
| extern AVOutputFormat rm_muxer; | |||
| extern AVOutputFormat rtp_muxer; | |||
| extern AVInputFormat rtsp_demuxer; | |||
| extern AVInputFormat sdp_demuxer; | |||
| extern AVInputFormat redir_demuxer; | |||
| extern AVInputFormat segafilm_demuxer; | |||
| extern AVInputFormat vmd_demuxer; | |||
| extern AVInputFormat smacker_demuxer; | |||
| extern AVInputFormat sol_demuxer; | |||
| extern AVInputFormat swf_demuxer; | |||
| extern AVOutputFormat swf_muxer; | |||
| extern AVInputFormat tta_demuxer; | |||
| extern AVInputFormat v4l2_demuxer; | |||
| extern AVInputFormat voc_demuxer; | |||
| extern AVOutputFormat voc_muxer; | |||
| extern AVInputFormat wav_demuxer; | |||
| extern AVOutputFormat wav_muxer; | |||
| extern AVInputFormat wc3_demuxer; | |||
| extern AVInputFormat wsaud_demuxer; | |||
| extern AVInputFormat wsvqa_demuxer; | |||
| extern AVOutputFormat yuv4mpegpipe_muxer; | |||
| extern AVInputFormat yuv4mpegpipe_demuxer; | |||
| /* raw.c */ | |||
| int pcm_read_seek(AVFormatContext *s, | |||
| int stream_index, int64_t timestamp, int flags); | |||
| int raw_init(void); | |||
| /* mp3.c */ | |||
| int mp3_init(void); | |||
| /* yuv4mpeg.c */ | |||
| int yuv4mpeg_init(void); | |||
| /* ogg2.c */ | |||
| int ogg_init(void); | |||
| /* ogg.c */ | |||
| int libogg_init(void); | |||
| /* dv.c */ | |||
| int ff_dv_init(void); | |||
| /* ffm.c */ | |||
| int ffm_init(void); | |||
| /* rtsp.c */ | |||
| extern AVInputFormat redir_demuxer; | |||
| int redir_open(AVFormatContext **ic_ptr, ByteIOContext *f); | |||
| /* 4xm.c */ | |||
| int fourxm_init(void); | |||
| /* psxstr.c */ | |||
| int str_init(void); | |||
| /* idroq.c */ | |||
| int roq_init(void); | |||
| /* ipmovie.c */ | |||
| int ipmovie_init(void); | |||
| /* nut.c */ | |||
| int nut_init(void); | |||
| /* wc3movie.c */ | |||
| int wc3_init(void); | |||
| /* westwood.c */ | |||
| int westwood_init(void); | |||
| /* segafilm.c */ | |||
| int film_init(void); | |||
| /* idcin.c */ | |||
| int idcin_init(void); | |||
| /* flic.c */ | |||
| int flic_init(void); | |||
| /* sierravmd.c */ | |||
| int vmd_init(void); | |||
| /* matroska.c */ | |||
| int matroska_init(void); | |||
| /* sol.c */ | |||
| int sol_init(void); | |||
| /* electronicarts.c */ | |||
| int ea_init(void); | |||
| /* nsvdec.c */ | |||
| int nsvdec_init(void); | |||
| /* daud.c */ | |||
| int daud_init(void); | |||
| /* nuv.c */ | |||
| int nuv_init(void); | |||
| /* gxf.c */ | |||
| int gxf_init(void); | |||
| /* aiff.c */ | |||
| int ff_aiff_init(void); | |||
| /* voc.c */ | |||
| int voc_init(void); | |||
| /* tta.c */ | |||
| int tta_init(void); | |||
| /* adts.c */ | |||
| int ff_adts_init(void); | |||
| /* mm.c */ | |||
| int mm_init(void); | |||
| /* avs.c */ | |||
| int avs_init(void); | |||
| /* smacker.c */ | |||
| int smacker_init(void); | |||
| /* v4l2.c */ | |||
| int v4l2_init(void); | |||
| #if 0 | |||
| extern AVImageFormat pnm_image_format; | |||
| extern AVImageFormat pbm_image_format; | |||
| @@ -215,7 +215,8 @@ static int amr_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat amr_demuxer = { | |||
| #ifdef CONFIG_AMR_DEMUXER | |||
| AVInputFormat amr_demuxer = { | |||
| "amr", | |||
| "3gpp amr file format", | |||
| 0, /*priv_data_size*/ | |||
| @@ -224,9 +225,10 @@ static AVInputFormat amr_demuxer = { | |||
| amr_read_packet, | |||
| amr_read_close, | |||
| }; | |||
| #endif | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat amr_muxer = { | |||
| #ifdef CONFIG_AMR_MUXER | |||
| AVOutputFormat amr_muxer = { | |||
| "amr", | |||
| "3gpp amr file format", | |||
| "audio/amr", | |||
| @@ -239,12 +241,3 @@ static AVOutputFormat amr_muxer = { | |||
| amr_write_trailer, | |||
| }; | |||
| #endif | |||
| int amr_init(void) | |||
| { | |||
| av_register_input_format(&amr_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&amr_muxer); | |||
| #endif | |||
| return 0; | |||
| } | |||
| @@ -23,8 +23,6 @@ | |||
| #undef NDEBUG | |||
| #include <assert.h> | |||
| #ifdef CONFIG_MUXERS | |||
| #define ASF_INDEXED_INTERVAL 10000000 | |||
| #define ASF_INDEX_BLOCK 600 | |||
| @@ -823,6 +821,7 @@ static int asf_write_trailer(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| #ifdef CONFIG_ASF_MUXER | |||
| AVOutputFormat asf_muxer = { | |||
| "asf", | |||
| "asf format", | |||
| @@ -840,7 +839,9 @@ AVOutputFormat asf_muxer = { | |||
| asf_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| #endif | |||
| #ifdef CONFIG_ASF_STREAM_MUXER | |||
| AVOutputFormat asf_stream_muxer = { | |||
| "asf_stream", | |||
| "asf format", | |||
| @@ -858,4 +859,4 @@ AVOutputFormat asf_stream_muxer = { | |||
| asf_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| #endif //CONFIG_ASF_STREAM_MUXER | |||
| @@ -840,7 +840,7 @@ static int asf_read_seek(AVFormatContext *s, int stream_index, int64_t pts, int | |||
| return 0; | |||
| } | |||
| static AVInputFormat asf_demuxer = { | |||
| AVInputFormat asf_demuxer = { | |||
| "asf", | |||
| "asf format", | |||
| sizeof(ASFContext), | |||
| @@ -851,18 +851,3 @@ static AVInputFormat asf_demuxer = { | |||
| asf_read_seek, | |||
| asf_read_pts, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| extern AVOutputFormat asf_muxer; | |||
| extern AVOutputFormat asf_stream_muxer; | |||
| #endif //CONFIG_MUXERS | |||
| int asf_init(void) | |||
| { | |||
| av_register_input_format(&asf_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&asf_muxer); | |||
| av_register_output_format(&asf_stream_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| @@ -178,7 +178,8 @@ static int au_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat au_demuxer = { | |||
| #ifdef CONFIG_AU_DEMUXER | |||
| AVInputFormat au_demuxer = { | |||
| "au", | |||
| "SUN AU Format", | |||
| 0, | |||
| @@ -188,9 +189,10 @@ static AVInputFormat au_demuxer = { | |||
| au_read_close, | |||
| pcm_read_seek, | |||
| }; | |||
| #endif | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat au_muxer = { | |||
| #ifdef CONFIG_AU_MUXER | |||
| AVOutputFormat au_muxer = { | |||
| "au", | |||
| "SUN AU Format", | |||
| "audio/basic", | |||
| @@ -202,13 +204,4 @@ static AVOutputFormat au_muxer = { | |||
| au_write_packet, | |||
| au_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int au_init(void) | |||
| { | |||
| av_register_input_format(&au_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&au_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif //CONFIG_AU_MUXER | |||
| @@ -313,7 +313,8 @@ static int audio_read_close(AVFormatContext *s1) | |||
| return 0; | |||
| } | |||
| static AVInputFormat audio_demuxer = { | |||
| #ifdef CONFIG_AUDIO_DEMUXER | |||
| AVInputFormat audio_demuxer = { | |||
| "audio_device", | |||
| "audio grab and output", | |||
| sizeof(AudioData), | |||
| @@ -323,8 +324,10 @@ static AVInputFormat audio_demuxer = { | |||
| audio_read_close, | |||
| .flags = AVFMT_NOFILE, | |||
| }; | |||
| #endif | |||
| static AVOutputFormat audio_muxer = { | |||
| #ifdef CONFIG_AUDIO_MUXER | |||
| AVOutputFormat audio_muxer = { | |||
| "audio_device", | |||
| "audio grab and output", | |||
| "", | |||
| @@ -344,10 +347,4 @@ static AVOutputFormat audio_muxer = { | |||
| audio_write_trailer, | |||
| .flags = AVFMT_NOFILE, | |||
| }; | |||
| int audio_init(void) | |||
| { | |||
| av_register_input_format(&audio_demuxer); | |||
| av_register_output_format(&audio_muxer); | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -923,7 +923,7 @@ static int avi_probe(AVProbeData *p) | |||
| return 0; | |||
| } | |||
| static AVInputFormat avi_demuxer = { | |||
| AVInputFormat avi_demuxer = { | |||
| "avi", | |||
| "avi format", | |||
| sizeof(AVIContext), | |||
| @@ -933,9 +933,3 @@ static AVInputFormat avi_demuxer = { | |||
| avi_read_close, | |||
| avi_read_seek, | |||
| }; | |||
| int avidec_init(void) | |||
| { | |||
| av_register_input_format(&avi_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -24,7 +24,7 @@ | |||
| * - fill all fields if non streamed (nb_frames for example) | |||
| */ | |||
| #ifdef CONFIG_MUXERS | |||
| #ifdef CONFIG_AVI_MUXER | |||
| typedef struct AVIIentry { | |||
| unsigned int flags, pos, len; | |||
| } AVIIentry; | |||
| @@ -71,7 +71,7 @@ void end_tag(ByteIOContext *pb, offset_t start) | |||
| put_le32(pb, (uint32_t)(pos - start)); | |||
| url_fseek(pb, pos, SEEK_SET); | |||
| } | |||
| #endif //CONFIG_MUXERS | |||
| #endif //CONFIG_AVI_MUXER | |||
| /* Note: when encoding, the first matching tag is used, so order is | |||
| important if multiple tags possible for a given codec. */ | |||
| @@ -260,7 +260,7 @@ enum CodecID codec_get_wav_id(unsigned int tag) | |||
| return codec_get_id(codec_wav_tags, tag); | |||
| } | |||
| #ifdef CONFIG_MUXERS | |||
| #ifdef CONFIG_AVI_MUXER | |||
| /* BITMAPINFOHEADER header */ | |||
| void put_bmp_header(ByteIOContext *pb, AVCodecContext *enc, const CodecTag *tags, int for_asf) | |||
| { | |||
| @@ -762,7 +762,7 @@ static int avi_write_trailer(AVFormatContext *s) | |||
| return res; | |||
| } | |||
| static AVOutputFormat avi_muxer = { | |||
| AVOutputFormat avi_muxer = { | |||
| "avi", | |||
| "avi format", | |||
| "video/x-msvideo", | |||
| @@ -774,10 +774,4 @@ static AVOutputFormat avi_muxer = { | |||
| avi_write_packet, | |||
| avi_write_trailer, | |||
| }; | |||
| int avienc_init(void) | |||
| { | |||
| av_register_output_format(&avi_muxer); | |||
| return 0; | |||
| } | |||
| #endif //CONFIG_MUXERS | |||
| #endif //CONFIG_AVI_MUXER | |||
| @@ -41,9 +41,6 @@ typedef enum avs_block_type { | |||
| AVS_GAME_DATA = 0x04, | |||
| } avs_block_type_t; | |||
| #ifdef CONFIG_DEMUXERS | |||
| static int avs_probe(AVProbeData * p) | |||
| { | |||
| const uint8_t *d; | |||
| @@ -217,7 +214,7 @@ static int avs_read_close(AVFormatContext * s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat avs_demuxer = { | |||
| AVInputFormat avs_demuxer = { | |||
| "avs", | |||
| "avs format", | |||
| sizeof(avs_format_t), | |||
| @@ -226,13 +223,3 @@ static AVInputFormat avs_demuxer = { | |||
| avs_read_packet, | |||
| avs_read_close, | |||
| }; | |||
| #endif /* CONFIG_DEMUXERS */ | |||
| int avs_init(void) | |||
| { | |||
| #ifdef CONFIG_DEMUXERS | |||
| av_register_input_format(&avs_demuxer); | |||
| #endif /* CONFIG_DEMUXERS */ | |||
| return 0; | |||
| } | |||
| @@ -56,8 +56,8 @@ unsigned long update_adler32(unsigned long adler, const uint8_t *buf, unsigned i | |||
| } | |||
| return (s2 << 16) | s1; | |||
| } | |||
| #ifdef CONFIG_MUXERS | |||
| #ifdef CONFIG_CRC_MUXER | |||
| typedef struct CRCState { | |||
| uint32_t crcval; | |||
| } CRCState; | |||
| @@ -89,7 +89,9 @@ static int crc_write_trailer(struct AVFormatContext *s) | |||
| put_flush_packet(&s->pb); | |||
| return 0; | |||
| } | |||
| #endif | |||
| #ifdef CONFIG_FRAMECRC_MUXER | |||
| static int framecrc_write_packet(struct AVFormatContext *s, AVPacket *pkt) | |||
| { | |||
| uint32_t crc = update_adler32(0, pkt->data, pkt->size); | |||
| @@ -100,8 +102,10 @@ static int framecrc_write_packet(struct AVFormatContext *s, AVPacket *pkt) | |||
| put_flush_packet(&s->pb); | |||
| return 0; | |||
| } | |||
| #endif | |||
| static AVOutputFormat crc_muxer = { | |||
| #ifdef CONFIG_CRC_MUXER | |||
| AVOutputFormat crc_muxer = { | |||
| "crc", | |||
| "crc testing format", | |||
| NULL, | |||
| @@ -113,8 +117,9 @@ static AVOutputFormat crc_muxer = { | |||
| crc_write_packet, | |||
| crc_write_trailer, | |||
| }; | |||
| static AVOutputFormat framecrc_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_FRAMECRC_MUXER | |||
| AVOutputFormat framecrc_muxer = { | |||
| "framecrc", | |||
| "framecrc testing format", | |||
| NULL, | |||
| @@ -126,11 +131,4 @@ static AVOutputFormat framecrc_muxer = { | |||
| framecrc_write_packet, | |||
| NULL, | |||
| }; | |||
| int crc_init(void) | |||
| { | |||
| av_register_output_format(&crc_muxer); | |||
| av_register_output_format(&framecrc_muxer); | |||
| return 0; | |||
| } | |||
| #endif /* CONFIG_MUXERS */ | |||
| #endif | |||
| @@ -43,7 +43,7 @@ static int daud_packet(AVFormatContext *s, AVPacket *pkt) { | |||
| return ret; | |||
| } | |||
| static AVInputFormat daud_demuxer = { | |||
| AVInputFormat daud_demuxer = { | |||
| "daud", | |||
| "D-Cinema audio format", | |||
| 0, | |||
| @@ -54,10 +54,3 @@ static AVInputFormat daud_demuxer = { | |||
| NULL, | |||
| .extensions = "302", | |||
| }; | |||
| int daud_init(void) | |||
| { | |||
| av_register_input_format(&daud_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -180,7 +180,7 @@ static int dc1394_close(AVFormatContext * context) | |||
| return 0; | |||
| } | |||
| static AVInputFormat dc1394_demuxer = { | |||
| AVInputFormat dc1394_demuxer = { | |||
| .name = "dc1394", | |||
| .long_name = "dc1394 A/V grab", | |||
| .priv_data_size = sizeof(struct dc1394_data), | |||
| @@ -189,9 +189,3 @@ static AVInputFormat dc1394_demuxer = { | |||
| .read_close = dc1394_close, | |||
| .flags = AVFMT_NOFILE | |||
| }; | |||
| int dc1394_init(void) | |||
| { | |||
| av_register_input_format(&dc1394_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -1000,7 +1000,8 @@ static int dv_write_trailer(struct AVFormatContext *s) | |||
| } | |||
| #endif /* CONFIG_MUXERS */ | |||
| static AVInputFormat dv_demuxer = { | |||
| #ifdef CONFIG_DV_DEMUXER | |||
| AVInputFormat dv_demuxer = { | |||
| "dv", | |||
| "DV video format", | |||
| sizeof(RawDVContext), | |||
| @@ -1011,9 +1012,9 @@ static AVInputFormat dv_demuxer = { | |||
| dv_read_seek, | |||
| .extensions = "dv,dif", | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat dv_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_DV_MUXER | |||
| AVOutputFormat dv_muxer = { | |||
| "dv", | |||
| "DV video format", | |||
| NULL, | |||
| @@ -1026,12 +1027,3 @@ static AVOutputFormat dv_muxer = { | |||
| dv_write_trailer, | |||
| }; | |||
| #endif | |||
| int ff_dv_init(void) | |||
| { | |||
| av_register_input_format(&dv_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&dv_muxer); | |||
| #endif | |||
| return 0; | |||
| } | |||
| @@ -227,7 +227,7 @@ static int dv1394_close(AVFormatContext * context) | |||
| return 0; | |||
| } | |||
| static AVInputFormat dv1394_demuxer = { | |||
| AVInputFormat dv1394_demuxer = { | |||
| .name = "dv1394", | |||
| .long_name = "dv1394 A/V grab", | |||
| .priv_data_size = sizeof(struct dv1394_data), | |||
| @@ -236,9 +236,3 @@ static AVInputFormat dv1394_demuxer = { | |||
| .read_close = dv1394_close, | |||
| .flags = AVFMT_NOFILE | |||
| }; | |||
| int dv1394_init(void) | |||
| { | |||
| av_register_input_format(&dv1394_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -278,7 +278,7 @@ static int ea_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat ea_demuxer = { | |||
| AVInputFormat ea_demuxer = { | |||
| "ea", | |||
| "Electronic Arts Multimedia Format", | |||
| sizeof(EaDemuxContext), | |||
| @@ -287,9 +287,3 @@ static AVInputFormat ea_demuxer = { | |||
| ea_read_packet, | |||
| ea_read_close, | |||
| }; | |||
| int ea_init(void) | |||
| { | |||
| av_register_input_format(&ea_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -761,7 +761,8 @@ static int ffm_probe(AVProbeData *p) | |||
| return 0; | |||
| } | |||
| static AVInputFormat ffm_demuxer = { | |||
| #ifdef CONFIG_FFM_DEMUXER | |||
| AVInputFormat ffm_demuxer = { | |||
| "ffm", | |||
| "ffm format", | |||
| sizeof(FFMContext), | |||
| @@ -771,9 +772,9 @@ static AVInputFormat ffm_demuxer = { | |||
| ffm_read_close, | |||
| ffm_seek, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat ffm_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_FFM_MUXER | |||
| AVOutputFormat ffm_muxer = { | |||
| "ffm", | |||
| "ffm format", | |||
| "", | |||
| @@ -786,13 +787,4 @@ static AVOutputFormat ffm_muxer = { | |||
| ffm_write_packet, | |||
| ffm_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int ffm_init(void) | |||
| { | |||
| av_register_input_format(&ffm_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&ffm_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif //CONFIG_FFM_MUXER | |||
| @@ -208,7 +208,7 @@ static int flic_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat flic_demuxer = { | |||
| AVInputFormat flic_demuxer = { | |||
| "flic", | |||
| "FLI/FLC/FLX animation format", | |||
| sizeof(FlicDemuxContext), | |||
| @@ -217,9 +217,3 @@ static AVInputFormat flic_demuxer = { | |||
| flic_read_packet, | |||
| flic_read_close, | |||
| }; | |||
| int flic_init(void) | |||
| { | |||
| av_register_input_format(&flic_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -222,9 +222,3 @@ AVInputFormat flv_demuxer = { | |||
| .extensions = "flv", | |||
| .value = CODEC_ID_FLV1, | |||
| }; | |||
| int flvdec_init(void) | |||
| { | |||
| av_register_input_format(&flv_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -167,7 +167,7 @@ static int flv_write_packet(AVFormatContext *s, AVPacket *pkt) | |||
| return 0; | |||
| } | |||
| static AVOutputFormat flv_muxer = { | |||
| AVOutputFormat flv_muxer = { | |||
| "flv", | |||
| "flv format", | |||
| "video/x-flv", | |||
| @@ -183,9 +183,3 @@ static AVOutputFormat flv_muxer = { | |||
| flv_write_packet, | |||
| flv_write_trailer, | |||
| }; | |||
| int flvenc_init(void) | |||
| { | |||
| av_register_output_format(&flv_muxer); | |||
| return 0; | |||
| } | |||
| @@ -414,7 +414,7 @@ int gif_write(ByteIOContext *pb, AVImageInfo *info) | |||
| return 0; | |||
| } | |||
| static AVOutputFormat gif_muxer = { | |||
| AVOutputFormat gif_muxer = { | |||
| "gif", | |||
| "GIF Animation", | |||
| "image/gif", | |||
| @@ -426,12 +426,3 @@ static AVOutputFormat gif_muxer = { | |||
| gif_write_packet, | |||
| gif_write_trailer, | |||
| }; | |||
| extern AVInputFormat gif_demuxer; | |||
| int gif_init(void) | |||
| { | |||
| av_register_output_format(&gif_muxer); | |||
| av_register_input_format(&gif_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -636,5 +636,7 @@ AVImageFormat gif_image_format = { | |||
| gif_image_probe, | |||
| gif_read, | |||
| (1 << PIX_FMT_PAL8), | |||
| #ifdef CONFIG_GIF_MUXER | |||
| gif_write, | |||
| #endif | |||
| }; | |||
| @@ -365,7 +365,7 @@ static int grab_read_close(AVFormatContext *s1) | |||
| return 0; | |||
| } | |||
| static AVInputFormat video_grab_device_demuxer = { | |||
| AVInputFormat video_grab_device_demuxer = { | |||
| "video4linux", | |||
| "video grab", | |||
| sizeof(VideoData), | |||
| @@ -848,9 +848,3 @@ static int aiw_close(VideoData *s) | |||
| av_freep(&s->src_mem); | |||
| return 0; | |||
| } | |||
| int video_grab_init(void) | |||
| { | |||
| av_register_input_format(&video_grab_device_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -326,9 +326,3 @@ AVInputFormat video_grab_device_demuxer = { | |||
| grab_read_close, | |||
| .flags = AVFMT_NOFILE, | |||
| }; | |||
| int video_grab_init(void) | |||
| { | |||
| av_register_input_format(&video_grab_device_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -241,7 +241,7 @@ static int gxf_packet(AVFormatContext *s, AVPacket *pkt) { | |||
| return AVERROR_IO; | |||
| } | |||
| static AVInputFormat gxf_demuxer = { | |||
| AVInputFormat gxf_demuxer = { | |||
| "gxf", | |||
| "GXF format", | |||
| 0, | |||
| @@ -251,9 +251,3 @@ static AVInputFormat gxf_demuxer = { | |||
| NULL, | |||
| NULL, | |||
| }; | |||
| int gxf_init(void) { | |||
| av_register_input_format(&gxf_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -288,7 +288,7 @@ static int idcin_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat idcin_demuxer = { | |||
| AVInputFormat idcin_demuxer = { | |||
| "idcin", | |||
| "Id CIN format", | |||
| sizeof(IdcinDemuxContext), | |||
| @@ -297,9 +297,3 @@ static AVInputFormat idcin_demuxer = { | |||
| idcin_read_packet, | |||
| idcin_read_close, | |||
| }; | |||
| int idcin_init(void) | |||
| { | |||
| av_register_input_format(&idcin_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -278,7 +278,7 @@ static int roq_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat roq_demuxer = { | |||
| AVInputFormat roq_demuxer = { | |||
| "RoQ", | |||
| "Id RoQ format", | |||
| sizeof(RoqDemuxContext), | |||
| @@ -287,9 +287,3 @@ static AVInputFormat roq_demuxer = { | |||
| roq_read_packet, | |||
| roq_read_close, | |||
| }; | |||
| int roq_init(void) | |||
| { | |||
| av_register_input_format(&roq_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -339,8 +339,8 @@ static int img_write_trailer(AVFormatContext *s) | |||
| } | |||
| /* input */ | |||
| static AVInputFormat image_demuxer = { | |||
| #ifdef CONFIG_IMAGE_DEMUXER | |||
| AVInputFormat image_demuxer = { | |||
| "image", | |||
| "image sequence", | |||
| sizeof(VideoData), | |||
| @@ -352,8 +352,9 @@ static AVInputFormat image_demuxer = { | |||
| NULL, | |||
| AVFMT_NOFILE | AVFMT_NEEDNUMBER, | |||
| }; | |||
| static AVInputFormat imagepipe_demuxer = { | |||
| #endif | |||
| #ifdef CONFIG_IMAGEPIPE_DEMUXER | |||
| AVInputFormat imagepipe_demuxer = { | |||
| "imagepipe", | |||
| "piped image sequence", | |||
| sizeof(VideoData), | |||
| @@ -363,11 +364,11 @@ static AVInputFormat imagepipe_demuxer = { | |||
| img_read_close, | |||
| NULL, | |||
| }; | |||
| #endif | |||
| /* output */ | |||
| static AVOutputFormat image_muxer = { | |||
| #ifdef CONFIG_IMAGE_MUXER | |||
| AVOutputFormat image_muxer = { | |||
| "image", | |||
| "image sequence", | |||
| "", | |||
| @@ -381,8 +382,9 @@ static AVOutputFormat image_muxer = { | |||
| AVFMT_NOFILE | AVFMT_NEEDNUMBER | AVFMT_RAWPICTURE, | |||
| img_set_parameters, | |||
| }; | |||
| static AVOutputFormat imagepipe_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_IMAGEPIPE_MUXER | |||
| AVOutputFormat imagepipe_muxer = { | |||
| "imagepipe", | |||
| "piped image sequence", | |||
| "", | |||
| @@ -396,14 +398,4 @@ static AVOutputFormat imagepipe_muxer = { | |||
| AVFMT_RAWPICTURE, | |||
| img_set_parameters, | |||
| }; | |||
| int img_init(void) | |||
| { | |||
| av_register_input_format(&image_demuxer); | |||
| av_register_output_format(&image_muxer); | |||
| av_register_input_format(&imagepipe_demuxer); | |||
| av_register_output_format(&imagepipe_muxer); | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -364,8 +364,8 @@ static int img_write_trailer(AVFormatContext *s) | |||
| #endif /* CONFIG_MUXERS */ | |||
| /* input */ | |||
| static AVInputFormat image2_demuxer = { | |||
| #ifdef CONFIG_IMAGE2_DEMUXER | |||
| AVInputFormat image2_demuxer = { | |||
| "image2", | |||
| "image2 sequence", | |||
| sizeof(VideoData), | |||
| @@ -377,8 +377,9 @@ static AVInputFormat image2_demuxer = { | |||
| NULL, | |||
| AVFMT_NOFILE, | |||
| }; | |||
| static AVInputFormat image2pipe_demuxer = { | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2PIPE_DEMUXER | |||
| AVInputFormat image2pipe_demuxer = { | |||
| "image2pipe", | |||
| "piped image2 sequence", | |||
| sizeof(VideoData), | |||
| @@ -388,12 +389,11 @@ static AVInputFormat image2pipe_demuxer = { | |||
| img_read_close, | |||
| NULL, | |||
| }; | |||
| #endif | |||
| #ifdef CONFIG_MUXERS | |||
| /* output */ | |||
| static AVOutputFormat image2_muxer = { | |||
| #ifdef CONFIG_IMAGE2_MUXER | |||
| AVOutputFormat image2_muxer = { | |||
| "image2", | |||
| "image2 sequence", | |||
| "", | |||
| @@ -406,8 +406,9 @@ static AVOutputFormat image2_muxer = { | |||
| img_write_trailer, | |||
| AVFMT_NOFILE, | |||
| }; | |||
| static AVOutputFormat image2pipe_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_IMAGE2PIPE_MUXER | |||
| AVOutputFormat image2pipe_muxer = { | |||
| "image2pipe", | |||
| "piped image2 sequence", | |||
| "", | |||
| @@ -419,17 +420,4 @@ static AVOutputFormat image2pipe_muxer = { | |||
| img_write_packet, | |||
| img_write_trailer, | |||
| }; | |||
| #endif /* CONFIG_MUXERS */ | |||
| int img2_init(void) | |||
| { | |||
| av_register_input_format(&image2_demuxer); | |||
| av_register_input_format(&image2pipe_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&image2_muxer); | |||
| av_register_output_format(&image2pipe_muxer); | |||
| #endif | |||
| return 0; | |||
| } | |||
| @@ -612,7 +612,7 @@ static int ipmovie_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat ipmovie_demuxer = { | |||
| AVInputFormat ipmovie_demuxer = { | |||
| "ipmovie", | |||
| "Interplay MVE format", | |||
| sizeof(IPMVEContext), | |||
| @@ -621,10 +621,3 @@ static AVInputFormat ipmovie_demuxer = { | |||
| ipmovie_read_packet, | |||
| ipmovie_read_close, | |||
| }; | |||
| int ipmovie_init(void) | |||
| { | |||
| av_register_input_format(&ipmovie_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -160,7 +160,7 @@ static int jpeg_read(ByteIOContext *f, | |||
| return jctx.ret_code; | |||
| } | |||
| #ifdef CONFIG_MUXERS | |||
| #if defined(CONFIG_MUXERS) && defined(CONFIG_MJPEG_ENCODER) | |||
| static int jpeg_write(ByteIOContext *pb, AVImageInfo *info) | |||
| { | |||
| AVCodecContext *c; | |||
| @@ -230,7 +230,7 @@ AVImageFormat jpeg_image_format = { | |||
| jpeg_probe, | |||
| jpeg_read, | |||
| (1 << PIX_FMT_YUVJ420P) | (1 << PIX_FMT_YUVJ422P) | (1 << PIX_FMT_YUVJ444P), | |||
| #ifdef CONFIG_MUXERS | |||
| #if defined(CONFIG_MUXERS) && defined(CONFIG_MJPEG_ENCODER) | |||
| jpeg_write, | |||
| #else | |||
| NULL, | |||
| @@ -2635,7 +2635,7 @@ matroska_read_close (AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat matroska_demuxer = { | |||
| AVInputFormat matroska_demuxer = { | |||
| "matroska", | |||
| "Matroska file format", | |||
| sizeof(MatroskaDemuxContext), | |||
| @@ -2644,10 +2644,3 @@ static AVInputFormat matroska_demuxer = { | |||
| matroska_read_packet, | |||
| matroska_read_close, | |||
| }; | |||
| int | |||
| matroska_init(void) | |||
| { | |||
| av_register_input_format(&matroska_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -199,7 +199,7 @@ static int mm_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat mm_demuxer = { | |||
| AVInputFormat mm_demuxer = { | |||
| "mm", | |||
| "American Laser Games MM format", | |||
| sizeof(MmDemuxContext), | |||
| @@ -208,9 +208,3 @@ static AVInputFormat mm_demuxer = { | |||
| mm_read_packet, | |||
| mm_read_close, | |||
| }; | |||
| int mm_init(void) | |||
| { | |||
| av_register_input_format(&mm_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -301,8 +301,8 @@ static int mmf_read_seek(AVFormatContext *s, | |||
| return pcm_read_seek(s, stream_index, timestamp, flags); | |||
| } | |||
| static AVInputFormat mmf_demuxer = { | |||
| #ifdef CONFIG_MMF_DEMUXER | |||
| AVInputFormat mmf_demuxer = { | |||
| "mmf", | |||
| "mmf format", | |||
| sizeof(MMFContext), | |||
| @@ -312,9 +312,9 @@ static AVInputFormat mmf_demuxer = { | |||
| mmf_read_close, | |||
| mmf_read_seek, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat mmf_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_MMF_MUXER | |||
| AVOutputFormat mmf_muxer = { | |||
| "mmf", | |||
| "mmf format", | |||
| "application/vnd.smaf", | |||
| @@ -326,14 +326,4 @@ static AVOutputFormat mmf_muxer = { | |||
| mmf_write_packet, | |||
| mmf_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int ff_mmf_init(void) | |||
| { | |||
| av_register_input_format(&mmf_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&mmf_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -1907,7 +1907,7 @@ static int mov_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat mov_demuxer = { | |||
| AVInputFormat mov_demuxer = { | |||
| "mov,mp4,m4a,3gp,3g2,mj2", | |||
| "QuickTime/MPEG4/Motion JPEG 2000 format", | |||
| sizeof(MOVContext), | |||
| @@ -1917,9 +1917,3 @@ static AVInputFormat mov_demuxer = { | |||
| mov_read_close, | |||
| mov_read_seek, | |||
| }; | |||
| int mov_init(void) | |||
| { | |||
| av_register_input_format(&mov_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -1588,7 +1588,8 @@ static int mov_write_trailer(AVFormatContext *s) | |||
| return res; | |||
| } | |||
| static AVOutputFormat mov_muxer = { | |||
| #ifdef CONFIG_MOV_MUXER | |||
| AVOutputFormat mov_muxer = { | |||
| "mov", | |||
| "mov format", | |||
| NULL, | |||
| @@ -1601,8 +1602,9 @@ static AVOutputFormat mov_muxer = { | |||
| mov_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| static AVOutputFormat _3gp_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_TGP_MUXER | |||
| AVOutputFormat tgp_muxer = { | |||
| "3gp", | |||
| "3gp format", | |||
| NULL, | |||
| @@ -1615,8 +1617,9 @@ static AVOutputFormat _3gp_muxer = { | |||
| mov_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| static AVOutputFormat mp4_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_MP4_MUXER | |||
| AVOutputFormat mp4_muxer = { | |||
| "mp4", | |||
| "mp4 format", | |||
| "application/mp4", | |||
| @@ -1629,8 +1632,9 @@ static AVOutputFormat mp4_muxer = { | |||
| mov_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| static AVOutputFormat psp_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_PSP_MUXER | |||
| AVOutputFormat psp_muxer = { | |||
| "psp", | |||
| "psp mp4 format", | |||
| NULL, | |||
| @@ -1643,8 +1647,9 @@ static AVOutputFormat psp_muxer = { | |||
| mov_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| static AVOutputFormat _3g2_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_TG2_MUXER | |||
| AVOutputFormat tg2_muxer = { | |||
| "3g2", | |||
| "3gp2 format", | |||
| NULL, | |||
| @@ -1657,13 +1662,4 @@ static AVOutputFormat _3g2_muxer = { | |||
| mov_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| int movenc_init(void) | |||
| { | |||
| av_register_output_format(&mov_muxer); | |||
| av_register_output_format(&_3gp_muxer); | |||
| av_register_output_format(&mp4_muxer); | |||
| av_register_output_format(&psp_muxer); | |||
| av_register_output_format(&_3g2_muxer); | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -368,6 +368,7 @@ static int mp3_write_trailer(struct AVFormatContext *s) | |||
| } | |||
| #endif //CONFIG_MUXERS | |||
| #ifdef CONFIG_MP3_DEMUXER | |||
| AVInputFormat mp3_demuxer = { | |||
| "mp3", | |||
| "MPEG audio", | |||
| @@ -378,8 +379,8 @@ AVInputFormat mp3_demuxer = { | |||
| mp3_read_close, | |||
| .extensions = "mp2,mp3,m2a", /* XXX: use probe */ | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| #endif | |||
| #ifdef CONFIG_MP2_MUXER | |||
| AVOutputFormat mp2_muxer = { | |||
| "mp2", | |||
| "MPEG audio layer 2", | |||
| @@ -396,8 +397,8 @@ AVOutputFormat mp2_muxer = { | |||
| mp3_write_packet, | |||
| mp3_write_trailer, | |||
| }; | |||
| #ifdef CONFIG_MP3LAME | |||
| #endif | |||
| #ifdef CONFIG_MP3_MUXER | |||
| AVOutputFormat mp3_muxer = { | |||
| "mp3", | |||
| "MPEG audio layer 3", | |||
| @@ -411,16 +412,3 @@ AVOutputFormat mp3_muxer = { | |||
| mp3_write_trailer, | |||
| }; | |||
| #endif | |||
| #endif //CONFIG_MUXERS | |||
| int mp3_init(void) | |||
| { | |||
| av_register_input_format(&mp3_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&mp2_muxer); | |||
| #ifdef CONFIG_MP3LAME | |||
| av_register_output_format(&mp3_muxer); | |||
| #endif | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| @@ -108,11 +108,11 @@ typedef struct { | |||
| static const int lpcm_freq_tab[4] = { 48000, 96000, 44100, 32000 }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat mpeg1system_muxer; | |||
| static AVOutputFormat mpeg1vcd_muxer; | |||
| static AVOutputFormat mpeg2vob_muxer; | |||
| static AVOutputFormat mpeg2svcd_muxer; | |||
| static AVOutputFormat mpeg2dvd_muxer; | |||
| AVOutputFormat mpeg1system_muxer; | |||
| AVOutputFormat mpeg1vcd_muxer; | |||
| AVOutputFormat mpeg2vob_muxer; | |||
| AVOutputFormat mpeg2svcd_muxer; | |||
| AVOutputFormat mpeg2dvd_muxer; | |||
| static int put_pack_header(AVFormatContext *ctx, | |||
| uint8_t *buf, int64_t timestamp) | |||
| @@ -1712,8 +1712,8 @@ static int64_t mpegps_read_dts(AVFormatContext *s, int stream_index, | |||
| return dts; | |||
| } | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat mpeg1system_muxer = { | |||
| #ifdef CONFIG_MPEG1SYSTEM_MUXER | |||
| AVOutputFormat mpeg1system_muxer = { | |||
| "mpeg", | |||
| "MPEG1 System format", | |||
| "video/mpeg", | |||
| @@ -1725,8 +1725,9 @@ static AVOutputFormat mpeg1system_muxer = { | |||
| mpeg_mux_write_packet, | |||
| mpeg_mux_end, | |||
| }; | |||
| static AVOutputFormat mpeg1vcd_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_MPEG1VCD_MUXER | |||
| AVOutputFormat mpeg1vcd_muxer = { | |||
| "vcd", | |||
| "MPEG1 System format (VCD)", | |||
| "video/mpeg", | |||
| @@ -1738,8 +1739,9 @@ static AVOutputFormat mpeg1vcd_muxer = { | |||
| mpeg_mux_write_packet, | |||
| mpeg_mux_end, | |||
| }; | |||
| static AVOutputFormat mpeg2vob_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_MPEG2VOB_MUXER | |||
| AVOutputFormat mpeg2vob_muxer = { | |||
| "vob", | |||
| "MPEG2 PS format (VOB)", | |||
| "video/mpeg", | |||
| @@ -1751,9 +1753,11 @@ static AVOutputFormat mpeg2vob_muxer = { | |||
| mpeg_mux_write_packet, | |||
| mpeg_mux_end, | |||
| }; | |||
| #endif | |||
| /* Same as mpeg2vob_muxer except that the pack size is 2324 */ | |||
| static AVOutputFormat mpeg2svcd_muxer = { | |||
| /* Same as mpeg2vob_mux except that the pack size is 2324 */ | |||
| #ifdef CONFIG_MPEG2SVCD_MUXER | |||
| AVOutputFormat mpeg2svcd_muxer = { | |||
| "svcd", | |||
| "MPEG2 PS format (VOB)", | |||
| "video/mpeg", | |||
| @@ -1765,9 +1769,11 @@ static AVOutputFormat mpeg2svcd_muxer = { | |||
| mpeg_mux_write_packet, | |||
| mpeg_mux_end, | |||
| }; | |||
| #endif | |||
| /* Same as mpeg2vob_muxer except the 'is_dvd' flag is set to produce NAV pkts */ | |||
| static AVOutputFormat mpeg2dvd_muxer = { | |||
| /* Same as mpeg2vob_mux except the 'is_dvd' flag is set to produce NAV pkts */ | |||
| #ifdef CONFIG_MPEG2DVD_MUXER | |||
| AVOutputFormat mpeg2dvd_muxer = { | |||
| "dvd", | |||
| "MPEG2 PS format (DVD VOB)", | |||
| "video/mpeg", | |||
| @@ -1779,9 +1785,9 @@ static AVOutputFormat mpeg2dvd_muxer = { | |||
| mpeg_mux_write_packet, | |||
| mpeg_mux_end, | |||
| }; | |||
| #endif | |||
| #endif //CONFIG_MUXERS | |||
| #ifdef CONFIG_MPEGPS_DEMUXER | |||
| AVInputFormat mpegps_demuxer = { | |||
| "mpeg", | |||
| "MPEG PS format", | |||
| @@ -1794,16 +1800,4 @@ AVInputFormat mpegps_demuxer = { | |||
| mpegps_read_dts, | |||
| .flags = AVFMT_SHOW_IDS, | |||
| }; | |||
| int mpegps_init(void) | |||
| { | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&mpeg1system_muxer); | |||
| av_register_output_format(&mpeg1vcd_muxer); | |||
| av_register_output_format(&mpeg2vob_muxer); | |||
| av_register_output_format(&mpeg2svcd_muxer); | |||
| av_register_output_format(&mpeg2dvd_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| av_register_input_format(&mpegps_demuxer); | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -1523,12 +1523,3 @@ AVInputFormat mpegts_demuxer = { | |||
| mpegts_get_pcr, | |||
| .flags = AVFMT_SHOW_IDS, | |||
| }; | |||
| int mpegts_init(void) | |||
| { | |||
| av_register_input_format(&mpegts_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&mpegts_muxer); | |||
| #endif | |||
| return 0; | |||
| } | |||
| @@ -22,7 +22,6 @@ | |||
| /* write DVB SI sections */ | |||
| #ifdef CONFIG_MUXERS | |||
| /*********************************************/ | |||
| /* mpegts section writer */ | |||
| @@ -673,4 +672,3 @@ AVOutputFormat mpegts_muxer = { | |||
| mpegts_write_packet, | |||
| mpegts_write_end, | |||
| }; | |||
| #endif // CONFIG_MUXERS | |||
| @@ -22,7 +22,6 @@ | |||
| #define BOUNDARY_TAG "ffserver" | |||
| #ifdef CONFIG_MUXERS | |||
| static int mpjpeg_write_header(AVFormatContext *s) | |||
| { | |||
| uint8_t buf1[256]; | |||
| @@ -52,7 +51,7 @@ static int mpjpeg_write_trailer(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVOutputFormat mpjpeg_muxer = { | |||
| AVOutputFormat mpjpeg_muxer = { | |||
| "mpjpeg", | |||
| "Mime multipart JPEG format", | |||
| "multipart/x-mixed-replace;boundary=" BOUNDARY_TAG, | |||
| @@ -64,10 +63,3 @@ static AVOutputFormat mpjpeg_muxer = { | |||
| mpjpeg_write_packet, | |||
| mpjpeg_write_trailer, | |||
| }; | |||
| int jpeg_init(void) | |||
| { | |||
| av_register_output_format(&mpjpeg_muxer); | |||
| return 0; | |||
| } | |||
| #endif //CONFIG_MUXERS | |||
| @@ -742,7 +742,7 @@ static int nsv_probe(AVProbeData *p) | |||
| return 0; | |||
| } | |||
| static AVInputFormat nsv_demuxer = { | |||
| AVInputFormat nsv_demuxer = { | |||
| "nsv", | |||
| "NullSoft Video format", | |||
| sizeof(NSVContext), | |||
| @@ -752,9 +752,3 @@ static AVInputFormat nsv_demuxer = { | |||
| nsv_read_close, | |||
| nsv_read_seek, | |||
| }; | |||
| int nsvdec_init(void) | |||
| { | |||
| av_register_input_format(&nsv_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -1419,7 +1419,8 @@ static int nut_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat nut_demuxer = { | |||
| #ifdef CONFIG_NUT_DEMUXER | |||
| AVInputFormat nut_demuxer = { | |||
| "nut", | |||
| "nut format", | |||
| sizeof(NUTContext), | |||
| @@ -1431,9 +1432,9 @@ static AVInputFormat nut_demuxer = { | |||
| nut_read_timestamp, | |||
| .extensions = "nut", | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat nut_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_NUT_MUXER | |||
| AVOutputFormat nut_muxer = { | |||
| "nut", | |||
| "nut format", | |||
| "video/x-nut", | |||
| @@ -1452,13 +1453,4 @@ static AVOutputFormat nut_muxer = { | |||
| nut_write_trailer, | |||
| .flags = AVFMT_GLOBALHEADER, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int nut_init(void) | |||
| { | |||
| av_register_input_format(&nut_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&nut_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -227,7 +227,7 @@ static int nuv_packet(AVFormatContext *s, AVPacket *pkt) { | |||
| return AVERROR_IO; | |||
| } | |||
| static AVInputFormat nuv_demuxer = { | |||
| AVInputFormat nuv_demuxer = { | |||
| "nuv", | |||
| "NuppelVideo format", | |||
| sizeof(NUVContext), | |||
| @@ -237,9 +237,3 @@ static AVInputFormat nuv_demuxer = { | |||
| NULL, | |||
| NULL, | |||
| }; | |||
| int nuv_init(void) { | |||
| av_register_input_format(&nuv_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -137,7 +137,7 @@ static int ogg_write_trailer(AVFormatContext *avfcontext) { | |||
| } | |||
| static AVOutputFormat ogg_muxer = { | |||
| AVOutputFormat ogg_muxer = { | |||
| "ogg", | |||
| "Ogg Vorbis", | |||
| "audio/x-vorbis", | |||
| @@ -254,7 +254,7 @@ static int ogg_read_close(AVFormatContext *avfcontext) { | |||
| } | |||
| static AVInputFormat ogg_demuxer = { | |||
| static AVInputFormat ogg_iformat = { | |||
| "ogg", | |||
| "Ogg Vorbis", | |||
| sizeof(OggContext), | |||
| @@ -265,11 +265,3 @@ static AVInputFormat ogg_demuxer = { | |||
| .extensions = "ogg", | |||
| } ; | |||
| #endif | |||
| int libogg_init(void) { | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&ogg_muxer) ; | |||
| #endif | |||
| /* av_register_input_format(&ogg_demuxer); */ | |||
| return 0 ; | |||
| } | |||
| @@ -65,7 +65,7 @@ ogg_write_trailer (AVFormatContext * avfcontext) | |||
| } | |||
| static AVOutputFormat ogg_muxer = { | |||
| AVOutputFormat ogg_muxer = { | |||
| "ogg", | |||
| "Ogg Vorbis", | |||
| "audio/x-vorbis", | |||
| @@ -656,7 +656,7 @@ static int ogg_probe(AVProbeData *p) | |||
| return 0; | |||
| } | |||
| static AVInputFormat ogg_demuxer = { | |||
| AVInputFormat ogg_demuxer = { | |||
| "ogg", | |||
| "Ogg", | |||
| sizeof (ogg_t), | |||
| @@ -668,13 +668,3 @@ static AVInputFormat ogg_demuxer = { | |||
| // ogg_read_timestamp, | |||
| .extensions = "ogg", | |||
| }; | |||
| int | |||
| ogg_init (void) | |||
| { | |||
| #if 0 // CONFIG_MUXERS | |||
| av_register_output_format (&ogg_muxer); | |||
| #endif | |||
| av_register_input_format (&ogg_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -351,7 +351,7 @@ static int str_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat str_demuxer = { | |||
| AVInputFormat str_demuxer = { | |||
| "psxstr", | |||
| "Sony Playstation STR format", | |||
| sizeof(StrDemuxContext), | |||
| @@ -360,9 +360,3 @@ static AVInputFormat str_demuxer = { | |||
| str_read_packet, | |||
| str_read_close, | |||
| }; | |||
| int str_init(void) | |||
| { | |||
| av_register_input_format(&str_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -813,70 +813,3 @@ AVOutputFormat null_muxer = { | |||
| .flags = AVFMT_NOFILE | AVFMT_RAWPICTURE, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| #ifndef CONFIG_MUXERS | |||
| #define av_register_output_format(format) | |||
| #endif | |||
| #ifndef CONFIG_DEMUXERS | |||
| #define av_register_input_format(format) | |||
| #endif | |||
| int raw_init(void) | |||
| { | |||
| av_register_input_format(&shorten_demuxer); | |||
| av_register_input_format(&flac_demuxer); | |||
| av_register_output_format(&flac_muxer); | |||
| av_register_input_format(&ac3_demuxer); | |||
| av_register_output_format(&ac3_muxer); | |||
| av_register_input_format(&aac_demuxer); | |||
| av_register_input_format(&dts_demuxer); | |||
| av_register_input_format(&h261_demuxer); | |||
| av_register_output_format(&h261_muxer); | |||
| av_register_input_format(&h263_demuxer); | |||
| av_register_output_format(&h263_muxer); | |||
| av_register_input_format(&m4v_demuxer); | |||
| av_register_output_format(&m4v_muxer); | |||
| av_register_input_format(&h264_demuxer); | |||
| av_register_output_format(&h264_muxer); | |||
| av_register_input_format(&mpegvideo_demuxer); | |||
| av_register_output_format(&mpeg1video_muxer); | |||
| av_register_output_format(&mpeg2video_muxer); | |||
| av_register_input_format(&mjpeg_demuxer); | |||
| av_register_output_format(&mjpeg_muxer); | |||
| av_register_input_format(&ingenient_demuxer); | |||
| av_register_input_format(&pcm_s16le_demuxer); | |||
| av_register_output_format(&pcm_s16le_muxer); | |||
| av_register_input_format(&pcm_s16be_demuxer); | |||
| av_register_output_format(&pcm_s16be_muxer); | |||
| av_register_input_format(&pcm_u16le_demuxer); | |||
| av_register_output_format(&pcm_u16le_muxer); | |||
| av_register_input_format(&pcm_u16be_demuxer); | |||
| av_register_output_format(&pcm_u16be_muxer); | |||
| av_register_input_format(&pcm_s8_demuxer); | |||
| av_register_output_format(&pcm_s8_muxer); | |||
| av_register_input_format(&pcm_u8_demuxer); | |||
| av_register_output_format(&pcm_u8_muxer); | |||
| av_register_input_format(&pcm_mulaw_demuxer); | |||
| av_register_output_format(&pcm_mulaw_muxer); | |||
| av_register_input_format(&pcm_alaw_demuxer); | |||
| av_register_output_format(&pcm_alaw_muxer); | |||
| av_register_input_format(&rawvideo_demuxer); | |||
| av_register_output_format(&rawvideo_muxer); | |||
| av_register_output_format(&null_muxer); | |||
| return 0; | |||
| } | |||
| @@ -1122,7 +1122,8 @@ static int64_t rm_read_dts(AVFormatContext *s, int stream_index, | |||
| return dts; | |||
| } | |||
| static AVInputFormat rm_demuxer = { | |||
| #ifdef CONFIG_RM_DEMUXER | |||
| AVInputFormat rm_demuxer = { | |||
| "rm", | |||
| "rm format", | |||
| sizeof(RMContext), | |||
| @@ -1133,9 +1134,9 @@ static AVInputFormat rm_demuxer = { | |||
| NULL, | |||
| rm_read_dts, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat rm_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_RM_MUXER | |||
| AVOutputFormat rm_muxer = { | |||
| "rm", | |||
| "rm format", | |||
| "application/vnd.rn-realmedia", | |||
| @@ -1147,13 +1148,4 @@ static AVOutputFormat rm_muxer = { | |||
| rm_write_packet, | |||
| rm_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int rm_init(void) | |||
| { | |||
| av_register_input_format(&rm_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&rm_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -872,9 +872,3 @@ AVOutputFormat rtp_muxer = { | |||
| rtp_write_packet, | |||
| rtp_write_trailer, | |||
| }; | |||
| int rtp_init(void) | |||
| { | |||
| av_register_output_format(&rtp_muxer); | |||
| return 0; | |||
| } | |||
| @@ -1345,8 +1345,8 @@ static int sdp_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat sdp_demuxer = { | |||
| #ifdef CONFIG_SDP_DEMUXER | |||
| AVInputFormat sdp_demuxer = { | |||
| "sdp", | |||
| "SDP", | |||
| sizeof(RTSPState), | |||
| @@ -1355,7 +1355,7 @@ static AVInputFormat sdp_demuxer = { | |||
| sdp_read_packet, | |||
| sdp_read_close, | |||
| }; | |||
| #endif | |||
| /* dummy redirector format (used directly in av_open_input_file now) */ | |||
| static int redir_probe(AVProbeData *pd) | |||
| @@ -1419,11 +1419,3 @@ AVInputFormat redir_demuxer = { | |||
| NULL, | |||
| NULL, | |||
| }; | |||
| int rtsp_init(void) | |||
| { | |||
| av_register_input_format(&rtsp_demuxer); | |||
| av_register_input_format(&redir_demuxer); | |||
| av_register_input_format(&sdp_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -297,7 +297,7 @@ static int film_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat film_demuxer = { | |||
| AVInputFormat segafilm_demuxer = { | |||
| "film_cpk", | |||
| "Sega FILM/CPK format", | |||
| sizeof(FilmDemuxContext), | |||
| @@ -306,9 +306,3 @@ static AVInputFormat film_demuxer = { | |||
| film_read_packet, | |||
| film_read_close, | |||
| }; | |||
| int film_init(void) | |||
| { | |||
| av_register_input_format(&film_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -319,7 +319,7 @@ static int vmd_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat vmd_demuxer = { | |||
| AVInputFormat vmd_demuxer = { | |||
| "vmd", | |||
| "Sierra VMD format", | |||
| sizeof(VmdDemuxContext), | |||
| @@ -328,9 +328,3 @@ static AVInputFormat vmd_demuxer = { | |||
| vmd_read_packet, | |||
| vmd_read_close, | |||
| }; | |||
| int vmd_init(void) | |||
| { | |||
| av_register_input_format(&vmd_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -332,7 +332,7 @@ static int smacker_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat smacker_demuxer = { | |||
| AVInputFormat smacker_demuxer = { | |||
| "smk", | |||
| "Smacker Video", | |||
| sizeof(SmackerContext), | |||
| @@ -341,9 +341,3 @@ static AVInputFormat smacker_demuxer = { | |||
| smacker_read_packet, | |||
| smacker_read_close, | |||
| }; | |||
| int smacker_init(void) | |||
| { | |||
| av_register_input_format(&smacker_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -146,7 +146,7 @@ static int sol_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat sol_demuxer = { | |||
| AVInputFormat sol_demuxer = { | |||
| "sol", | |||
| "Sierra SOL Format", | |||
| 0, | |||
| @@ -156,9 +156,3 @@ static AVInputFormat sol_demuxer = { | |||
| sol_read_close, | |||
| pcm_read_seek, | |||
| }; | |||
| int sol_init(void) | |||
| { | |||
| av_register_input_format(&sol_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -899,7 +899,8 @@ static int swf_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat swf_demuxer = { | |||
| #ifdef CONFIG_SWF_DEMUXER | |||
| AVInputFormat swf_demuxer = { | |||
| "swf", | |||
| "Flash format", | |||
| sizeof(SWFContext), | |||
| @@ -908,9 +909,9 @@ static AVInputFormat swf_demuxer = { | |||
| swf_read_packet, | |||
| swf_read_close, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat swf_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_SWF_MUXER | |||
| AVOutputFormat swf_muxer = { | |||
| "swf", | |||
| "Flash format", | |||
| "application/x-shockwave-flash", | |||
| @@ -922,13 +923,4 @@ static AVOutputFormat swf_muxer = { | |||
| swf_write_packet, | |||
| swf_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int swf_init(void) | |||
| { | |||
| av_register_input_format(&swf_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&swf_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -149,9 +149,3 @@ AVInputFormat tta_demuxer = { | |||
| tta_read_close, | |||
| .extensions = "tta", | |||
| }; | |||
| int tta_init(void) | |||
| { | |||
| av_register_input_format(&tta_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -90,11 +90,13 @@ AVOutputFormat *guess_format(const char *short_name, const char *filename, | |||
| int score_max, score; | |||
| /* specific test for image sequences */ | |||
| #ifdef CONFIG_IMAGE2_MUXER | |||
| if (!short_name && filename && | |||
| filename_number_test(filename) >= 0 && | |||
| av_guess_image2_codec(filename) != CODEC_ID_NONE) { | |||
| return guess_format("image2", NULL, NULL); | |||
| } | |||
| #endif | |||
| if (!short_name && filename && | |||
| filename_number_test(filename) >= 0 && | |||
| guess_image_format(filename)) { | |||
| @@ -151,9 +153,11 @@ enum CodecID av_guess_codec(AVOutputFormat *fmt, const char *short_name, | |||
| if(type == CODEC_TYPE_VIDEO){ | |||
| enum CodecID codec_id= CODEC_ID_NONE; | |||
| #ifdef CONFIG_IMAGE2_MUXER | |||
| if(!strcmp(fmt->name, "image2") || !strcmp(fmt->name, "image2pipe")){ | |||
| codec_id= av_guess_image2_codec(filename); | |||
| } | |||
| #endif | |||
| if(codec_id == CODEC_ID_NONE) | |||
| codec_id= fmt->video_codec; | |||
| return codec_id; | |||
| @@ -1730,7 +1734,9 @@ static void av_estimate_timings(AVFormatContext *ic) | |||
| } | |||
| ic->file_size = file_size; | |||
| if ((ic->iformat == &mpegps_demuxer || ic->iformat == &mpegts_demuxer) && file_size && !ic->pb.is_streamed) { | |||
| if ((!strcmp(ic->iformat->name, "mpeg") || | |||
| !strcmp(ic->iformat->name, "mpegts")) && | |||
| file_size && !ic->pb.is_streamed) { | |||
| /* get accurate estimate from the PTSes */ | |||
| av_estimate_timings_from_pts(ic); | |||
| } else if (av_has_timings(ic)) { | |||
| @@ -522,7 +522,7 @@ static int v4l2_read_close(AVFormatContext *s1) | |||
| return 0; | |||
| } | |||
| static AVInputFormat v4l2_demuxer = { | |||
| AVInputFormat v4l2_demuxer = { | |||
| "video4linux2", | |||
| "video grab", | |||
| sizeof(struct video_data), | |||
| @@ -532,9 +532,3 @@ static AVInputFormat v4l2_demuxer = { | |||
| v4l2_read_close, | |||
| .flags = AVFMT_NOFILE, | |||
| }; | |||
| int v4l2_init(void) | |||
| { | |||
| av_register_input_format(&v4l2_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -173,7 +173,7 @@ static int voc_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat voc_demuxer = { | |||
| AVInputFormat voc_demuxer = { | |||
| "voc", | |||
| "Creative Voice File format", | |||
| sizeof(voc_dec_context_t), | |||
| @@ -256,7 +256,7 @@ static int voc_write_trailer(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVOutputFormat voc_muxer = { | |||
| AVOutputFormat voc_muxer = { | |||
| "voc", | |||
| "Creative Voice File format", | |||
| "audio/x-voc", | |||
| @@ -270,15 +270,3 @@ static AVOutputFormat voc_muxer = { | |||
| }; | |||
| #endif /* CONFIG_MUXERS */ | |||
| int voc_init(void) | |||
| { | |||
| #ifdef CONFIG_DEMUXERS | |||
| av_register_input_format(&voc_demuxer); | |||
| #endif /* CONFIG_DEMUXERS */ | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&voc_muxer); | |||
| #endif /* CONFIG_MUXERS */ | |||
| return 0; | |||
| } | |||
| @@ -404,8 +404,8 @@ static int wav_read_seek(AVFormatContext *s, | |||
| return pcm_read_seek(s, stream_index, timestamp, flags); | |||
| } | |||
| static AVInputFormat wav_demuxer = { | |||
| #ifdef CONFIG_WAV_DEMUXER | |||
| AVInputFormat wav_demuxer = { | |||
| "wav", | |||
| "wav format", | |||
| sizeof(WAVContext), | |||
| @@ -415,9 +415,9 @@ static AVInputFormat wav_demuxer = { | |||
| wav_read_close, | |||
| wav_read_seek, | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static AVOutputFormat wav_muxer = { | |||
| #endif | |||
| #ifdef CONFIG_WAV_MUXER | |||
| AVOutputFormat wav_muxer = { | |||
| "wav", | |||
| "wav format", | |||
| "audio/x-wav", | |||
| @@ -429,13 +429,4 @@ static AVOutputFormat wav_muxer = { | |||
| wav_write_packet, | |||
| wav_write_trailer, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| int ff_wav_init(void) | |||
| { | |||
| av_register_input_format(&wav_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&wav_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -381,7 +381,7 @@ static int wc3_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat wc3_demuxer = { | |||
| AVInputFormat wc3_demuxer = { | |||
| "wc3movie", | |||
| "Wing Commander III movie format", | |||
| sizeof(Wc3DemuxContext), | |||
| @@ -390,9 +390,3 @@ static AVInputFormat wc3_demuxer = { | |||
| wc3_read_packet, | |||
| wc3_read_close, | |||
| }; | |||
| int wc3_init(void) | |||
| { | |||
| av_register_input_format(&wc3_demuxer); | |||
| return 0; | |||
| } | |||
| @@ -357,7 +357,8 @@ static int wsvqa_read_close(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| static AVInputFormat wsaud_demuxer = { | |||
| #ifdef CONFIG_WSAUD_DEMUXER | |||
| AVInputFormat wsaud_demuxer = { | |||
| "wsaud", | |||
| "Westwood Studios audio format", | |||
| sizeof(WsAudDemuxContext), | |||
| @@ -366,8 +367,9 @@ static AVInputFormat wsaud_demuxer = { | |||
| wsaud_read_packet, | |||
| wsaud_read_close, | |||
| }; | |||
| static AVInputFormat wsvqa_demuxer = { | |||
| #endif | |||
| #ifdef CONFIG_WSVQA_DEMUXER | |||
| AVInputFormat wsvqa_demuxer = { | |||
| "wsvqa", | |||
| "Westwood Studios VQA format", | |||
| sizeof(WsVqaDemuxContext), | |||
| @@ -376,10 +378,4 @@ static AVInputFormat wsvqa_demuxer = { | |||
| wsvqa_read_packet, | |||
| wsvqa_read_close, | |||
| }; | |||
| int westwood_init(void) | |||
| { | |||
| av_register_input_format(&wsaud_demuxer); | |||
| av_register_input_format(&wsvqa_demuxer); | |||
| return 0; | |||
| } | |||
| #endif | |||
| @@ -27,8 +27,6 @@ struct frame_attributes { | |||
| int top_field_first; | |||
| }; | |||
| #ifdef CONFIG_MUXERS | |||
| static int yuv4_generate_header(AVFormatContext *s, char* buf) | |||
| { | |||
| AVStream *st; | |||
| @@ -171,6 +169,7 @@ static int yuv4_write_trailer(AVFormatContext *s) | |||
| return 0; | |||
| } | |||
| #ifdef CONFIG_YUV4MPEGPIPE_MUXER | |||
| AVOutputFormat yuv4mpegpipe_muxer = { | |||
| "yuv4mpegpipe", | |||
| "YUV4MPEG pipe format", | |||
| @@ -184,7 +183,7 @@ AVOutputFormat yuv4mpegpipe_muxer = { | |||
| yuv4_write_trailer, | |||
| .flags = AVFMT_RAWPICTURE, | |||
| }; | |||
| #endif //CONFIG_MUXERS | |||
| #endif | |||
| /* Header size increased to allow room for optional flags */ | |||
| #define MAX_YUV4_HEADER 80 | |||
| @@ -393,6 +392,7 @@ static int yuv4_probe(AVProbeData *pd) | |||
| return 0; | |||
| } | |||
| #ifdef CONFIG_YUV4MPEGPIPE_DEMUXER | |||
| AVInputFormat yuv4mpegpipe_demuxer = { | |||
| "yuv4mpegpipe", | |||
| "YUV4MPEG pipe format", | |||
| @@ -403,13 +403,4 @@ AVInputFormat yuv4mpegpipe_demuxer = { | |||
| yuv4_read_close, | |||
| .extensions = "y4m" | |||
| }; | |||
| int yuv4mpeg_init(void) | |||
| { | |||
| av_register_input_format(&yuv4mpegpipe_demuxer); | |||
| #ifdef CONFIG_MUXERS | |||
| av_register_output_format(&yuv4mpegpipe_muxer); | |||
| #endif //CONFIG_MUXERS | |||
| return 0; | |||
| } | |||
| #endif | |||