#include <image_filesinput.h>
Inheritance diagram for mimas::image_filesinput< T >:
Public Member Functions | |
image_filesinput (void) | |
Constructor. | |
void | addFileName (const std::string &fileName) |
Add a filename to the list. | |
virtual void | read (image< T > &image) throw (mimasexception) |
Read the next image file. | |
Protected Attributes | |
std::deque< std::string > | fileNames |
List of filenames. |
Example of usage:
using namespace mimas; int main( int argc, char *argv[] ) { image_filesinput< rgba< unsigned char > > input; for ( int i=1; i<argc; i++ ) input.addFileName( argv[i] ); ... image< rgba< unsigned char > > image; while ( input >> image ) { ... }; }
Definition at line 31 of file image_filesinput.h.
mimas::image_filesinput< T >::image_filesinput | ( | void | ) | [inline, explicit] |
void mimas::image_filesinput< T >::addFileName | ( | const std::string & | fileName | ) | [inline] |
Add a filename to the list.
A filename is added to the end of the list.
Definition at line 38 of file image_filesinput.h.
References mimas::image_filesinput< T >::fileNames.
virtual void mimas::image_filesinput< T >::read | ( | image< T > & | image | ) | throw (mimasexception) [virtual] |
Read the next image file.
The first filename in the list is removed and the file with this name is opened. The content of the file is read into the image.
image | Object to store image in. |
Implements mimas::image_input< T >.
std::deque< std::string > mimas::image_filesinput< T >::fileNames [protected] |
List of filenames.
Definition at line 47 of file image_filesinput.h.
Referenced by mimas::image_filesinput< T >::addFileName().