Statistics
| Branch: | Revision:

ffmpeg / libavformat / allformats.c @ 54bc6403

History | View | Annotate | Download (8.82 KB)

1
/*
2
 * Register all the formats and protocols
3
 * Copyright (c) 2000, 2001, 2002 Fabrice Bellard
4
 *
5
 * This file is part of FFmpeg.
6
 *
7
 * FFmpeg is free software; you can redistribute it and/or
8
 * modify it under the terms of the GNU Lesser General Public
9
 * License as published by the Free Software Foundation; either
10
 * version 2.1 of the License, or (at your option) any later version.
11
 *
12
 * FFmpeg is distributed in the hope that it will be useful,
13
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
15
 * Lesser General Public License for more details.
16
 *
17
 * You should have received a copy of the GNU Lesser General Public
18
 * License along with FFmpeg; if not, write to the Free Software
19
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
20
 */
21
#include "avformat.h"
22
#include "rtp.h"
23
#include "rdt.h"
24

    
25
#define REGISTER_MUXER(X,x) { \
26
    extern AVOutputFormat x##_muxer; \
27
    if(CONFIG_##X##_MUXER) av_register_output_format(&x##_muxer); }
28

    
29
#define REGISTER_DEMUXER(X,x) { \
30
    extern AVInputFormat x##_demuxer; \
31
    if(CONFIG_##X##_DEMUXER) av_register_input_format(&x##_demuxer); }
32

    
33
#define REGISTER_MUXDEMUX(X,x)  REGISTER_MUXER(X,x); REGISTER_DEMUXER(X,x)
34

    
35
#define REGISTER_PROTOCOL(X,x) { \
36
    extern URLProtocol x##_protocol; \
37
    if(CONFIG_##X##_PROTOCOL) av_register_protocol2(&x##_protocol, sizeof(x##_protocol)); }
38

    
39
void av_register_all(void)
40
{
41
    static int initialized;
42

    
43
    if (initialized)
44
        return;
45
    initialized = 1;
46

    
47
    avcodec_register_all();
48

    
49
    /* (de)muxers */
50
    REGISTER_MUXER    (A64, a64);
51
    REGISTER_DEMUXER  (AAC, aac);
52
    REGISTER_MUXDEMUX (AC3, ac3);
53
    REGISTER_MUXER    (ADTS, adts);
54
    REGISTER_DEMUXER  (AEA, aea);
55
    REGISTER_MUXDEMUX (AIFF, aiff);
56
    REGISTER_MUXDEMUX (AMR, amr);
57
    REGISTER_DEMUXER  (ANM, anm);
58
    REGISTER_DEMUXER  (APC, apc);
59
    REGISTER_DEMUXER  (APE, ape);
60
    REGISTER_DEMUXER  (APPLEHTTP, applehttp);
61
    REGISTER_MUXDEMUX (ASF, asf);
62
    REGISTER_MUXDEMUX (ASS, ass);
63
    REGISTER_MUXER    (ASF_STREAM, asf_stream);
64
    REGISTER_MUXDEMUX (AU, au);
65
    REGISTER_MUXDEMUX (AVI, avi);
66
    REGISTER_DEMUXER  (AVISYNTH, avisynth);
67
    REGISTER_MUXER    (AVM2, avm2);
68
    REGISTER_DEMUXER  (AVS, avs);
69
    REGISTER_DEMUXER  (BETHSOFTVID, bethsoftvid);
70
    REGISTER_DEMUXER  (BFI, bfi);
71
    REGISTER_DEMUXER  (BINK, bink);
72
    REGISTER_DEMUXER  (C93, c93);
73
    REGISTER_DEMUXER  (CAF, caf);
74
    REGISTER_MUXDEMUX (CAVSVIDEO, cavsvideo);
75
    REGISTER_DEMUXER  (CDG, cdg);
76
    REGISTER_MUXER    (CRC, crc);
77
    REGISTER_MUXDEMUX (DAUD, daud);
78
    REGISTER_MUXDEMUX (DIRAC, dirac);
79
    REGISTER_MUXDEMUX (DNXHD, dnxhd);
80
    REGISTER_DEMUXER  (DSICIN, dsicin);
81
    REGISTER_MUXDEMUX (DTS, dts);
82
    REGISTER_MUXDEMUX (DV, dv);
83
    REGISTER_DEMUXER  (DXA, dxa);
84
    REGISTER_DEMUXER  (EA, ea);
85
    REGISTER_DEMUXER  (EA_CDATA, ea_cdata);
86
    REGISTER_MUXDEMUX (EAC3, eac3);
87
    REGISTER_MUXDEMUX (FFM, ffm);
88
    REGISTER_MUXDEMUX (FFMETADATA, ffmetadata);
89
    REGISTER_MUXDEMUX (FILMSTRIP, filmstrip);
90
    REGISTER_MUXDEMUX (FLAC, flac);
91
    REGISTER_DEMUXER  (FLIC, flic);
92
    REGISTER_MUXDEMUX (FLV, flv);
93
    REGISTER_DEMUXER  (FOURXM, fourxm);
94
    REGISTER_MUXER    (FRAMECRC, framecrc);
95
    REGISTER_MUXER    (FRAMEMD5, framemd5);
96
    REGISTER_MUXDEMUX (G722, g722);
97
    REGISTER_MUXER    (GIF, gif);
98
    REGISTER_DEMUXER  (GSM, gsm);
99
    REGISTER_MUXDEMUX (GXF, gxf);
100
    REGISTER_MUXDEMUX (H261, h261);
101
    REGISTER_MUXDEMUX (H263, h263);
102
    REGISTER_MUXDEMUX (H264, h264);
103
    REGISTER_DEMUXER  (IDCIN, idcin);
104
    REGISTER_DEMUXER  (IFF, iff);
105
    REGISTER_MUXDEMUX (IMAGE2, image2);
106
    REGISTER_MUXDEMUX (IMAGE2PIPE, image2pipe);
107
    REGISTER_DEMUXER  (INGENIENT, ingenient);
108
    REGISTER_DEMUXER  (IPMOVIE, ipmovie);
109
    REGISTER_MUXER    (IPOD, ipod);
110
    REGISTER_DEMUXER  (ISS, iss);
111
    REGISTER_DEMUXER  (IV8, iv8);
112
    REGISTER_MUXDEMUX (IVF, ivf);
113
    REGISTER_DEMUXER  (LMLM4, lmlm4);
114
    REGISTER_DEMUXER  (LXF, lxf);
115
    REGISTER_MUXDEMUX (M4V, m4v);
116
    REGISTER_MUXER    (MD5, md5);
117
    REGISTER_MUXDEMUX (MATROSKA, matroska);
118
    REGISTER_MUXER    (MATROSKA_AUDIO, matroska_audio);
119
    REGISTER_MUXDEMUX (MJPEG, mjpeg);
120
    REGISTER_MUXDEMUX (MLP, mlp);
121
    REGISTER_DEMUXER  (MM, mm);
122
    REGISTER_MUXDEMUX (MMF, mmf);
123
    REGISTER_MUXDEMUX (MOV, mov);
124
    REGISTER_MUXER    (MP2, mp2);
125
    REGISTER_MUXDEMUX (MP3, mp3);
126
    REGISTER_MUXER    (MP4, mp4);
127
    REGISTER_DEMUXER  (MPC, mpc);
128
    REGISTER_DEMUXER  (MPC8, mpc8);
129
    REGISTER_MUXER    (MPEG1SYSTEM, mpeg1system);
130
    REGISTER_MUXER    (MPEG1VCD, mpeg1vcd);
131
    REGISTER_MUXER    (MPEG1VIDEO, mpeg1video);
132
    REGISTER_MUXER    (MPEG2DVD, mpeg2dvd);
133
    REGISTER_MUXER    (MPEG2SVCD, mpeg2svcd);
134
    REGISTER_MUXER    (MPEG2VIDEO, mpeg2video);
135
    REGISTER_MUXER    (MPEG2VOB, mpeg2vob);
136
    REGISTER_DEMUXER  (MPEGPS, mpegps);
137
    REGISTER_MUXDEMUX (MPEGTS, mpegts);
138
    REGISTER_DEMUXER  (MPEGTSRAW, mpegtsraw);
139
    REGISTER_DEMUXER  (MPEGVIDEO, mpegvideo);
140
    REGISTER_MUXER    (MPJPEG, mpjpeg);
141
    REGISTER_DEMUXER  (MSNWC_TCP, msnwc_tcp);
142
    REGISTER_DEMUXER  (MTV, mtv);
143
    REGISTER_DEMUXER  (MVI, mvi);
144
    REGISTER_MUXDEMUX (MXF, mxf);
145
    REGISTER_MUXER    (MXF_D10, mxf_d10);
146
    REGISTER_DEMUXER  (MXG, mxg);
147
    REGISTER_DEMUXER  (NC, nc);
148
    REGISTER_DEMUXER  (NSV, nsv);
149
    REGISTER_MUXER    (NULL, null);
150
    REGISTER_MUXDEMUX (NUT, nut);
151
    REGISTER_DEMUXER  (NUV, nuv);
152
    REGISTER_MUXDEMUX (OGG, ogg);
153
    REGISTER_DEMUXER  (OMA, oma);
154
    REGISTER_MUXDEMUX (PCM_ALAW,  pcm_alaw);
155
    REGISTER_MUXDEMUX (PCM_MULAW, pcm_mulaw);
156
    REGISTER_MUXDEMUX (PCM_F64BE, pcm_f64be);
157
    REGISTER_MUXDEMUX (PCM_F64LE, pcm_f64le);
158
    REGISTER_MUXDEMUX (PCM_F32BE, pcm_f32be);
159
    REGISTER_MUXDEMUX (PCM_F32LE, pcm_f32le);
160
    REGISTER_MUXDEMUX (PCM_S32BE, pcm_s32be);
161
    REGISTER_MUXDEMUX (PCM_S32LE, pcm_s32le);
162
    REGISTER_MUXDEMUX (PCM_S24BE, pcm_s24be);
163
    REGISTER_MUXDEMUX (PCM_S24LE, pcm_s24le);
164
    REGISTER_MUXDEMUX (PCM_S16BE, pcm_s16be);
165
    REGISTER_MUXDEMUX (PCM_S16LE, pcm_s16le);
166
    REGISTER_MUXDEMUX (PCM_S8,    pcm_s8);
167
    REGISTER_MUXDEMUX (PCM_U32BE, pcm_u32be);
168
    REGISTER_MUXDEMUX (PCM_U32LE, pcm_u32le);
169
    REGISTER_MUXDEMUX (PCM_U24BE, pcm_u24be);
170
    REGISTER_MUXDEMUX (PCM_U24LE, pcm_u24le);
171
    REGISTER_MUXDEMUX (PCM_U16BE, pcm_u16be);
172
    REGISTER_MUXDEMUX (PCM_U16LE, pcm_u16le);
173
    REGISTER_MUXDEMUX (PCM_U8,    pcm_u8);
174
    REGISTER_MUXER    (PSP, psp);
175
    REGISTER_DEMUXER  (PVA, pva);
176
    REGISTER_DEMUXER  (QCP, qcp);
177
    REGISTER_DEMUXER  (R3D, r3d);
178
    REGISTER_MUXDEMUX (RAWVIDEO, rawvideo);
179
    REGISTER_DEMUXER  (RL2, rl2);
180
    REGISTER_MUXDEMUX (RM, rm);
181
    REGISTER_MUXDEMUX (ROQ, roq);
182
    REGISTER_DEMUXER  (RPL, rpl);
183
    REGISTER_MUXDEMUX (RSO, rso);
184
    REGISTER_MUXDEMUX (RTP, rtp);
185
    REGISTER_MUXDEMUX (RTSP, rtsp);
186
    REGISTER_MUXDEMUX (SAP, sap);
187
    REGISTER_DEMUXER  (SDP, sdp);
188
#if CONFIG_RTPDEC
189
    av_register_rtp_dynamic_payload_handlers();
190
    av_register_rdt_dynamic_payload_handlers();
191
#endif
192
    REGISTER_DEMUXER  (SEGAFILM, segafilm);
193
    REGISTER_DEMUXER  (SHORTEN, shorten);
194
    REGISTER_DEMUXER  (SIFF, siff);
195
    REGISTER_DEMUXER  (SMACKER, smacker);
196
    REGISTER_DEMUXER  (SOL, sol);
197
    REGISTER_MUXDEMUX (SOX, sox);
198
    REGISTER_MUXDEMUX (SPDIF, spdif);
199
    REGISTER_MUXDEMUX (SRT, srt);
200
    REGISTER_DEMUXER  (STR, str);
201
    REGISTER_MUXDEMUX (SWF, swf);
202
    REGISTER_MUXER    (TG2, tg2);
203
    REGISTER_MUXER    (TGP, tgp);
204
    REGISTER_DEMUXER  (THP, thp);
205
    REGISTER_DEMUXER  (TIERTEXSEQ, tiertexseq);
206
    REGISTER_DEMUXER  (TMV, tmv);
207
    REGISTER_MUXDEMUX (TRUEHD, truehd);
208
    REGISTER_DEMUXER  (TTA, tta);
209
    REGISTER_DEMUXER  (TXD, txd);
210
    REGISTER_DEMUXER  (TTY, tty);
211
    REGISTER_DEMUXER  (VC1, vc1);
212
    REGISTER_MUXDEMUX (VC1T, vc1t);
213
    REGISTER_DEMUXER  (VMD, vmd);
214
    REGISTER_MUXDEMUX (VOC, voc);
215
    REGISTER_DEMUXER  (VQF, vqf);
216
    REGISTER_DEMUXER  (W64, w64);
217
    REGISTER_MUXDEMUX (WAV, wav);
218
    REGISTER_DEMUXER  (WC3, wc3);
219
    REGISTER_MUXER    (WEBM, webm);
220
    REGISTER_DEMUXER  (WSAUD, wsaud);
221
    REGISTER_DEMUXER  (WSVQA, wsvqa);
222
    REGISTER_DEMUXER  (WTV, wtv);
223
    REGISTER_DEMUXER  (WV, wv);
224
    REGISTER_DEMUXER  (XA, xa);
225
    REGISTER_DEMUXER  (YOP, yop);
226
    REGISTER_MUXDEMUX (YUV4MPEGPIPE, yuv4mpegpipe);
227

    
228
    /* external libraries */
229
    REGISTER_MUXDEMUX (LIBNUT, libnut);
230

    
231
    /* protocols */
232
    REGISTER_PROTOCOL (CONCAT, concat);
233
    REGISTER_PROTOCOL (FILE, file);
234
    REGISTER_PROTOCOL (GOPHER, gopher);
235
    REGISTER_PROTOCOL (HTTP, http);
236
    REGISTER_PROTOCOL (MMSH, mmsh);
237
    REGISTER_PROTOCOL (MMST, mmst);
238
    REGISTER_PROTOCOL (MD5,  md5);
239
    REGISTER_PROTOCOL (PIPE, pipe);
240
    REGISTER_PROTOCOL (RTMP, rtmp);
241
#if CONFIG_LIBRTMP
242
    REGISTER_PROTOCOL (RTMP, rtmpt);
243
    REGISTER_PROTOCOL (RTMP, rtmpe);
244
    REGISTER_PROTOCOL (RTMP, rtmpte);
245
    REGISTER_PROTOCOL (RTMP, rtmps);
246
#endif
247
    REGISTER_PROTOCOL (RTP, rtp);
248
    REGISTER_PROTOCOL (TCP, tcp);
249
    REGISTER_PROTOCOL (UDP, udp);
250
}