#include <archon/util/image.H>
Inheritance diagram for Archon::Utilities::Image::Format:
Public Member Functions | |
virtual string | getSpecifier () const =0 |
Must return the unique specifier for this image format. | |
virtual bool | checkSignature (Ref< Stream::Reader >) const =0 |
Check if the initial characters from the passed stream identifies the stream contents as being of this format. | |
virtual bool | checkSuffix (string suffix) const =0 |
Check if the passed suffix is a proper file name suffix for this format. | |
virtual Image | load (Ref< Stream::Reader >, ProgressTracker *, Logger *) const =0 throw (InvalidFormatException, IOException, UnexpectedException) |
virtual void | save (Image, Ref< Stream::Writer >, ProgressTracker *, Logger *) const =0 throw (IOException, UnexpectedException) |
virtual | ~Format () |
Ensures proper destruction of derived classes. | |
Protected Member Functions | |
char * | getPixelBufferNoLeak (const Image &i) const |
A backdoor allowing loaders to get hold of a non-const pointer to the pixel buffer without putting the Rep object into the leaked state which would result in an otherwise redundant copying of the image data. |
It could be PNG or it could be JPEG or it could be anything else.
It is an abstract base class or interface listing the methods required for interaction with the image loader and image saver. Objects of this type are offered for service through the Context object.
Definition at line 360 of file image.H.
|
Check if the passed suffix is a proper file name suffix for this format.
Implemented in Archon::Utilities::FormatLibgif, Archon::Utilities::FormatLibjpeg, and Archon::Utilities::FormatLibpng. |
|
A backdoor allowing loaders to get hold of a non-const pointer to the pixel buffer without putting the Rep object into the leaked state which would result in an otherwise redundant copying of the image data. Please do not use this member function for any other purpose. Definition at line 406 of file image.H. References Archon::Utilities::Image::getPixelBuffer(). Referenced by Archon::Utilities::FormatLibpng::load(), Archon::Utilities::FormatLibjpeg::load(), Archon::Utilities::FormatLibpng::save(), and Archon::Utilities::FormatLibjpeg::save(). |
|
Must return the unique specifier for this image format. The specifier is the sub-field of the MIME type. That is, the part of the MIME type after "image/". This will normally correspond to the file name suffix, but not always. Implemented in Archon::Utilities::FormatLibgif, Archon::Utilities::FormatLibjpeg, and Archon::Utilities::FormatLibpng. |