00001 // MediaHandlerFfmpeg.h: FFMPEG media handler, for Gnash 00002 // 00003 // Copyright (C) 2007, 2008, 2009, 2010 Free Software Foundation, Inc. 00004 // 00005 // This program is free software; you can redistribute it and/or modify 00006 // it under the terms of the GNU General Public License as published by 00007 // the Free Software Foundation; either version 3 of the License, or 00008 // (at your option) any later version. 00009 // 00010 // This program is distributed in the hope that it will be useful, 00011 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00013 // GNU General Public License for more details. 00014 // 00015 // You should have received a copy of the GNU General Public License 00016 // along with this program; if not, write to the Free Software 00017 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA 00018 00019 #ifndef GNASH_MEDIAHANDLERFFMPEG_H 00020 #define GNASH_MEDIAHANDLERFFMPEG_H 00021 00022 #include "MediaHandler.h" // for inheritance 00023 00024 #include <vector> 00025 #include <memory> 00026 00027 namespace gnash { 00028 namespace media { 00029 00031 // 00040 namespace ffmpeg { 00041 00043 class MediaHandlerFfmpeg : public MediaHandler 00044 { 00045 public: 00046 00047 std::string description() const; 00048 00049 virtual std::auto_ptr<MediaParser> 00050 createMediaParser(std::auto_ptr<IOChannel> stream); 00051 00052 virtual std::auto_ptr<VideoDecoder> 00053 createVideoDecoder(const VideoInfo& info); 00054 00055 virtual std::auto_ptr<VideoConverter> 00056 createVideoConverter(ImgBuf::Type4CC srcFormat, 00057 ImgBuf::Type4CC dstFormat); 00058 00059 virtual std::auto_ptr<AudioDecoder> 00060 createAudioDecoder(const AudioInfo& info); 00061 00062 virtual size_t getInputPaddingSize() const; 00063 00064 virtual VideoInput* getVideoInput(size_t index); 00065 00066 virtual AudioInput* getAudioInput(size_t index); 00067 00068 virtual void cameraNames(std::vector<std::string>& names) const; 00069 00070 }; 00071 00072 00073 } // gnash.media.ffmpeg namespace 00074 } // gnash.media namespace 00075 } // namespace gnash 00076 00077 #endif