xref: /haiku/src/add-ons/media/plugins/ffmpeg/FFmpegPlugin.h (revision 5ac9b506412b11afb993bb52d161efe7666958a5)
1 /*
2  * Copyright (C) 2001 Carlos Hasan. All Rights Reserved.
3  * Copyright (C) 2001 François Revol. All Rights Reserved.
4  * Copyright (C) 2001 Axel Dörfler. All Rights Reserved.
5  * Copyright (C) 2004 Marcus Overhagen. All Rights Reserved.
6  *
7  * Distributed under the terms of the MIT License.
8  */
9 #ifndef FFMPEG_PLUGIN_H
10 #define FFMPEG_PLUGIN_H
11 
12 
13 #include <MediaFormats.h>
14 
15 #include <Decoder.h>
16 #include <Encoder.h>
17 #include <Reader.h>
18 #include <Writer.h>
19 
20 using namespace BCodecKit;
21 
22 
23 class FFmpegPlugin : public BReaderPlugin, public BDecoderPlugin,
24 	public BWriterPlugin, public BEncoderPlugin {
25 public:
26 	virtual	BReader*			NewReader();
27 
28 	virtual	BDecoder*			NewDecoder(uint index);
29 	virtual	status_t			GetSupportedFormats(media_format** _formats,
30 									size_t* _count);
31 
32 	virtual	BWriter*			NewWriter();
33 	virtual	status_t			GetSupportedFileFormats(
34 									const media_file_format** _fileFormats,
35 									size_t* _count);
36 
37 	virtual	BEncoder*			NewEncoder(
38 									const media_codec_info& codecInfo);
39 
40 	virtual	BEncoder*			NewEncoder(const media_format& format);
41 
42 	virtual	status_t			RegisterNextEncoder(int32* cookie,
43 									media_codec_info* codecInfo,
44 									media_format_family* formatFamily,
45 									media_format* inputFormat,
46 									media_format* outputFormat);
47 };
48 
49 
50 #endif // FFMPEG_PLUGIN_H
51