| synfig-core
    1.0.3
    | 
Used for importing bitmaps of various formats, including animations. More...
#include <importer.h>
 
  
 | Classes | |
| struct | BookEntry | 
| Public Types | |
| typedef Importer *(* | Factory )(const FileSystem::Identifier &identifier) | 
| typedef std::map< std::string, BookEntry > | Book | 
| typedef etl::handle< Importer > | Handle | 
| typedef etl::loose_handle < Importer > | LooseHandle | 
| typedef etl::handle< const Importer > | ConstHandle | 
| Public Member Functions | |
| Gamma & | gamma () | 
| const Gamma & | gamma () const | 
| virtual | ~Importer () | 
| virtual bool | get_frame (Surface &surface, const RendDesc &renddesc, Time time, ProgressCallback *callback=NULL)=0 | 
| Gets a frame and puts it into surface. | |
| virtual bool | get_frame (Surface &surface, const RendDesc &renddesc, Time time, bool &trimmed __attribute__((unused)), unsigned int &width __attribute__((unused)), unsigned int &height __attribute__((unused)), unsigned int &top __attribute__((unused)), unsigned int &left __attribute__((unused)), ProgressCallback *callback=NULL) | 
| virtual bool | is_animated () | 
| Returns trueif the importer pays attention to the time parameter of get_frame() | |
| Static Public Member Functions | |
| static Book & | book () | 
| static bool | subsys_init () | 
| static bool | subsys_stop () | 
| static Handle | open (const FileSystem::Identifier &identifier) | 
| Attempts to open filename, and returns a handle to the associated Importer. | |
| Public Attributes | |
| const FileSystem::Identifier | identifier | 
| Static Public Attributes | |
| static Book * | book_ | 
| Protected Member Functions | |
| Importer (const FileSystem::Identifier &identifier) | |
Used for importing bitmaps of various formats, including animations.
It is the base class for all the importers. It defines the has a static Book pointer class that is a map for the importers factory creators and the strings of the extension that the importer can understand. It allows to create the a pointer to a particular importer just by using the extension of the name of file to import. Also it creates a virtual member get_frame that must be declared in the inherited classes.
| typedef Importer*(* synfig::Importer::Factory)(const FileSystem::Identifier &identifier) | 
| typedef std::map<std::string,BookEntry> synfig::Importer::Book | 
| typedef etl::handle<Importer> synfig::Importer::Handle | 
| typedef etl::loose_handle<Importer> synfig::Importer::LooseHandle | 
| typedef etl::handle<const Importer> synfig::Importer::ConstHandle | 
| 
 | protected | 
| 
 | virtual | 
References __open_importers.
| 
 | static | 
References book_.
Referenced by synfig::Main::Main(), and OptionsProcessor::process_info_options().
| 
 | static | 
Initializes the Import module by creating a book of importers names and its creators and the list of open importers
References __open_importers, and book_.
Referenced by synfig::Main::Main().
| 
 | static | 
Stops the Import module by deleting the book and the list of open importers
References __open_importers, and book_.
Referenced by synfig::Main::Main(), and synfig::Main::~Main().
| 
 | inline | 
Referenced by imagemagick_mptr::get_frame(), jpeg_mptr::jpeg_mptr(), and png_mptr::png_mptr().
| 
 | inline | 
| 
 | pure virtual | 
Gets a frame and puts it into surface.
| surface | Reference to surface to put frame into | 
| time | For animated importers, determines which frame to get. For static importers, this parameter is unused. | 
| callback | Pointer to callback class for progress, errors, etc. | 
true on success, false on error Implemented in ffmpeg_mptr, synfig::ListImporter, jpeg_mptr, png_mptr, imagemagick_mptr, Importer_LibAVCodec, bmp_mptr, exr_mptr, mplayer_mptr, and ppm_mptr.
Referenced by get_frame().
| 
 | inlinevirtual | 
References get_frame().
| 
 | inlinevirtual | 
Returns true if the importer pays attention to the time parameter of get_frame() 
Reimplemented in ffmpeg_mptr, and synfig::ListImporter.
| 
 | static | 
Attempts to open filename, and returns a handle to the associated Importer.
References _, __open_importers, synfig::error(), synfig::FileSystem::Identifier::filename, and tolower.
Referenced by synfig::ListImporter::get_frame().
| 
 | static | 
| const FileSystem::Identifier synfig::Importer::identifier | 
Referenced by imagemagick_mptr::get_frame().
 1.8.1.2
 1.8.1.2