#include <rw2image.hpp>
Public Member Functions | |
Creators | |
Rw2Image (BasicIo::AutoPtr io) | |
Constructor to open an existing RW2 image. Since the constructor can not return a result, callers should check the good() method after object construction to determine success or failure. | |
Manipulators | |
void | readMetadata () |
Read all metadata supported by a specific image format from the image. Before this method is called, the image metadata will be cleared. | |
void | writeMetadata () |
Todo: Write metadata back to the image. This method is not yet implemented. Calling it will throw an Error(31). | |
void | setExifData (const ExifData &exifData) |
Todo: Not supported yet, requires writeMetadata(). Calling this function will throw an Error(32). | |
void | setIptcData (const IptcData &iptcData) |
Todo: Not supported yet, requires writeMetadata(). Calling this function will throw an Error(32). | |
void | setComment (const std::string &comment) |
Not supported. RW2 format does not contain a comment. Calling this function will throw an Error(32). | |
Accessors | |
std::string | mimeType () const |
Return the MIME type of the image. | |
int | pixelWidth () const |
Return the pixel width of the image. | |
int | pixelHeight () const |
Return the pixel height of the image. |
Exiv2::Rw2Image::Rw2Image | ( | BasicIo::AutoPtr | io | ) |
Constructor to open an existing RW2 image. Since the constructor can not return a result, callers should check the good() method after object construction to determine success or failure.
io | An auto-pointer that owns a BasicIo instance used for reading and writing image metadata. Important: The constructor takes ownership of the passed in BasicIo instance through the auto-pointer. Callers should not continue to use the BasicIo instance after it is passed to this method. Use the Image::io() method to get a temporary reference. |
void Exiv2::Rw2Image::readMetadata | ( | ) | [virtual] |
Read all metadata supported by a specific image format from the image. Before this method is called, the image metadata will be cleared.
This method returns success even if no metadata is found in the image. Callers must therefore check the size of individual metadata types before accessing the data.
Error | if opening or reading of the file fails or the image data is not valid (does not look like data of the specific image type). |
Implements Exiv2::Image.
std::string Exiv2::Rw2Image::mimeType | ( | ) | const [inline, virtual] |
Return the MIME type of the image.
Implements Exiv2::Image.