#include <pxl_metadata.h>
Public Types | |
| enum | FieldType { BYTE = 1, ASCII = 2, SHORT = 3, LONG = 4, RATIONAL = 5, SBYTE = 6, UNDEFINED = 7, SSHORT = 8, SLONG = 9, SRATIONAL = 10, FLOAT = 11, DOUBLE = 12, IFD = 13 } |
Static Public Member Functions | |
| static const size_t | sizeOf (u16 inType) |
| static const char * | getTypeName (u16 inType) |
| static String | getTagName (u16 inTag) |
| static u16 | getTagFromName (const String &inTagName) |
| static bool | isAcceptableType (u16 inTag, u16 inType) |
| static u16 | getPrimaryTypeForTag (u16 inTag) |
| static String | extractTagNameFromPath (const String &inPath) |
| static size_t | getStdCountForTag (u16 inTag) |
| static bool | isIFD (u16 inTag) |
| static bool | isImageIFD (u16 inTag) |
| static void | set (DataStore *inDataStore, u16 inTag, u16 inType, size_t inCount, const void *inData, Endian inEndian=endianHost) |
| static void | set (DataStore *inDataStore, const String &inTag, u16 inType, size_t inCount, const void *inData, Endian inEndian=endianHost) |
| static void | set (DataStore *inDataStore, const DATA &inData, Endian inEndian=endianHost) |
| static void | set (DataStore *inDataStore, const String &inTag, const String &inString) |
| static void | set (DataStore *inDataStore, u16 inTag, const String &inString) |
| static bool | verify (const DataStore *inDataStore, const String &inTag, u16 inType=0, size_t inCount=0) |
| static bool | verify (const DataStore *inDataStore, u16 inTag, u16 inType=0, size_t inCount=0) |
| static const void * | get (const DataStore *inDataStore, const String &inTag, u16 &outType, size_t &outCount) |
| static const void * | get (const DataStore *inDataStore, u16 inTag, u16 &outType, size_t &outCount) |
| static DATA | get (const DataStore *inDataStore, u16 inTag) |
| static DATA | get (const DataStore *inDataStore, const String &inTag) |
| static bool | isLegal (const DATA &inData) |
| static const u8 * | getAsBYTE (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const char * | getAsASCII (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const u16 * | getAsSHORT (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const u32 * | getAsLONG (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const TIFF_RATIONAL * | getAsRATIONAL (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const i8 * | getAsSBYTE (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const u8 * | getAsUNDEFINED (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const i16 * | getAsSSHORT (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const i32 * | getAsSLONG (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const TIFF_SRATIONAL * | getAsSRATIONAL (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const float * | getAsFLOAT (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static const double * | getAsDOUBLE (const DataStore *inDataStore, u16 inTag, size_t *outCount=NULL) |
| static String | getAsString (const DataStore *inDataStore, u16 inTag) |
| static const u8 * | getAsBYTE (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const char * | getAsASCII (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const u16 * | getAsSHORT (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const u32 * | getAsLONG (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const TIFF_RATIONAL * | getAsRATIONAL (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const i8 * | getAsSBYTE (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const u8 * | getAsUNDEFINED (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const i16 * | getAsSSHORT (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const i32 * | getAsSLONG (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const TIFF_SRATIONAL * | getAsSRATIONAL (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const float * | getAsFLOAT (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static const double * | getAsDOUBLE (const DataStore *inDataStore, const String &inTag, size_t *outCount=NULL) |
| static String | getAsString (const DataStore *inDataStore, const String &inTag) |
Classes | |
| struct | DATA |
For more information about metadata handling, see Metadata Handling.
For the list of supported TIFF tags, see Supported TIFF Tags.
Definition at line 39 of file pxl_metadata.h.
This enumeration defines the field types defined in TIFF 6.0 specification.
All types enumerated here is defined in TIFF 6.0 except IFD type. IFD type is defined in the following document:
"Adobe PageMaker(R) 6.0 TIFF Technical Notes"
1995, Adobe Systems Incorporated.
http://partners.adobe.com/asn/developer/pdfs/tn/TIFFPM6.pdf
Definition at line 51 of file pxl_metadata.h.
| static const size_t Celartem::TIFF6::sizeOf | ( | u16 | inType | ) | [static] |
This function returns the size of the specified type in bytes.
If this function does not know the specified type, this function throws errInvalidParam.
| inType | One of the FieldType value or any other field types that are defined in TIFF related specifications. |
Referenced by Celartem::TIFF6::DATA::getSize().
| static const char* Celartem::TIFF6::getTypeName | ( | u16 | inType | ) | [static] |
This function returns the human readable notation of the specified field type. For instance, "BYTE" is returned for 1 and "LONG" for 4. If this function does not know the specified type, this function throws errInvalidParam.
| inType | One of the FieldType value or any other field types that are defined in TIFF related specifications. |
This function returns the human readable notation of the specified tag. If this function does not know the specified tag, this function returns NULL.
| inTag | The tag in number. |
Referenced by Celartem::TIFF6::DATA::getTagName().
This function returns the tag number corresponding to the specified name. If this function does not know about the specified tag name, this function returns 0xffff.
| inTagName | The tag name. |
Referenced by Celartem::TIFF6::DATA::setTagName().
This function checks the specified type is valid for the specified tag. This function verifies the consistensy based on the internal TIFF tag table and if this function does not know about the tag, this function return false.
| inTag | The tag in number. | |
| inType | The field type. |
This function returns the primary field type for the specified tag. As you know, TIFF 6.0 allows some tags to use several field types, and then this function returns a suitable field type.
| inTag | The tag in number. |
| static size_t Celartem::TIFF6::getStdCountForTag | ( | u16 | inTag | ) | [static] |
This function returns the count of values of the specified tag. If the count of the values are not fixed, this function returns 0.
| inTag | The tag in number. |
| static bool Celartem::TIFF6::isIFD | ( | u16 | inTag | ) | [static] |
This function returns true if the specified tag acts as IFD pointer. This function returns true for all IDF(13) type tags, and also returns true for some LONG(4) type tags.
| inTag | The tag in number. |
true if the tag acts as IFD pointer, otherwise false. | static bool Celartem::TIFF6::isImageIFD | ( | u16 | inTag | ) | [static] |
This function returns true if the specified tag acts as IFD pointer and the IFD pointed has an image data.
| inTag | The tag in number. |
true if the tag acts as IFD pointer, otherwise false. | static void Celartem::TIFF6::set | ( | DataStore * | inDataStore, | |
| u16 | inTag, | |||
| u16 | inType, | |||
| size_t | inCount, | |||
| const void * | inData, | |||
| Endian | inEndian = endianHost | |||
| ) | [static] |
This function sets the specified data to the specified DataStore instance.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag in number. | |
| inType | The type of the TIFF tag. | |
| inCount | The count of the entries on the array specified by inData. | |
| inData | Pointer to the data array. | |
| inEndian | The endianness to write the data. |
| static void Celartem::TIFF6::set | ( | DataStore * | inDataStore, | |
| const String & | inTag, | |||
| u16 | inType, | |||
| size_t | inCount, | |||
| const void * | inData, | |||
| Endian | inEndian = endianHost | |||
| ) | [static] |
This function sets the specified data to the specified DataStore instance.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| inType | The type of the TIFF tag. | |
| inCount | The count of the entries on the array specified by inData. | |
| inData | Pointer to the data array. | |
| inEndian | The endianness to write the data. |
| static void Celartem::TIFF6::set | ( | DataStore * | inDataStore, | |
| const String & | inTag, | |||
| const String & | inString | |||
| ) | [static] |
This function sets the specified string to the specified DataStore instance as TIFF6::ASCII type.
Please note that PixelLive SDK actually set UTF-8 strings as ASCII strings and it may cause any charset/encoding problems.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| inString | The string to be set. |
| static void Celartem::TIFF6::set | ( | DataStore * | inDataStore, | |
| u16 | inTag, | |||
| const String & | inString | |||
| ) | [static] |
This function sets the specified string to the specified DataStore instance as TIFF6::ASCII type.
Please note that PixelLive SDK actually set UTF-8 strings as ASCII strings and it may cause any charset/encoding problems.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| inString | The string to be set. |
| static bool Celartem::TIFF6::verify | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| u16 | inType = 0, |
|||
| size_t | inCount = 0 | |||
| ) | [static] |
This function check the existance and type, count of the specified tag. You can assume that this function never throws any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| inType | If you want to verify the type of tag, set this parameter to the type. If you specify 0 to it, the function does not verify the type. | |
| inCount | If you want to verify the number of elements, set this parameter to the number of elements. If you specify 0 to it, the function does not verify the count. |
true if the verification success, otherwise false. | static bool Celartem::TIFF6::verify | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| u16 | inType = 0, |
|||
| size_t | inCount = 0 | |||
| ) | [static] |
This function check the existance and type, count of the specified tag. You can assume that this function never throws any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| inType | If you want to verify the type of tag, set this parameter to the type. If you specify 0 to it, the function does not verify the type. | |
| inCount | If you want to verify the number of elements, set this parameter to the number of elements. If you specify 0 to it, the function does not verify the count. |
true if the verification success, otherwise false. | static const void* Celartem::TIFF6::get | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| u16 & | outType, | |||
| size_t & | outCount | |||
| ) | [static] |
This function returns the specified TIFF tag data from the DataStore instance.
| inDataStore | The DataStore instance. | |
| inTag | The TIFF tag name. | |
| outType | The variable specified here obtains the TIFF field type of the specified tag on return. | |
| outCount | The variable specified here obtains the count of the data on return. |
| static const void* Celartem::TIFF6::get | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| u16 & | outType, | |||
| size_t & | outCount | |||
| ) | [static] |
This function returns the specified TIFF tag data from the DataStore instance.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outType | The variable specified here obtains the TIFF field type of the specified tag on return. | |
| outCount | The variable specified here obtains the count of the data on return. |
| static bool Celartem::TIFF6::isLegal | ( | const DATA & | inData | ) | [static] |
This function verifies the specified data.
| inData | The data to be verified. |
true if the data is valid, otherwise false. | static const u8* Celartem::TIFF6::getAsBYTE | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u8 array from the DataStore instance if the array type is TIFF6::BYTE. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const char* Celartem::TIFF6::getAsASCII | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a char array from the DataStore instance if the array type is TIFF6::ASCII. You can assume that the function does not throw any exceptions.
Please note that this function may return strings that contain non-ASCII characters if the original data contains them.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const u16* Celartem::TIFF6::getAsSHORT | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u16 array from the DataStore instance if the array type is TIFF6::SHORT. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. Referenced by Celartem::MetadataUtils::getResolutionUnit(), Celartem::MetadataUtils::getXResolution(), and Celartem::MetadataUtils::getYResolution().
| static const u32* Celartem::TIFF6::getAsLONG | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u32 array from the DataStore instance if the array type is TIFF6::LONG. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const TIFF_RATIONAL* Celartem::TIFF6::getAsRATIONAL | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a TIFF_RATIONAL array from the DataStore instance if the array type is TIFF6::RATIONAL. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. Referenced by Celartem::MetadataUtils::getXResolution(), and Celartem::MetadataUtils::getYResolution().
| static const i8* Celartem::TIFF6::getAsSBYTE | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a i8 array from the DataStore instance if the array type is TIFF6::SBYTE. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const u8* Celartem::TIFF6::getAsUNDEFINED | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u8 array from the DataStore instance if the array type is TIFF6::UNDEFINED. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const i16* Celartem::TIFF6::getAsSSHORT | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a i16 array from the DataStore instance if the array type is TIFF6::SSHORT. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const i32* Celartem::TIFF6::getAsSLONG | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a i32 array from the DataStore instance if the array type is TIFF6::SLONG. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const TIFF_SRATIONAL* Celartem::TIFF6::getAsSRATIONAL | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a TIFF_SRATIONAL array from the DataStore instance if the array type is TIFF6::SRATIONAL. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const float* Celartem::TIFF6::getAsFLOAT | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a float array from the DataStore instance if the array type is TIFF6::FLOAT. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const double* Celartem::TIFF6::getAsDOUBLE | ( | const DataStore * | inDataStore, | |
| u16 | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a double array from the DataStore instance if the array type is TIFF6::DOUBLE. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. This function returns the specified TIFF tag data as a String from the DataStore instance if the array type is TIFF6::ASCII. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. |
| static const u8* Celartem::TIFF6::getAsBYTE | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u8 array from the DataStore instance if the array type is TIFF6::BYTE. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const char* Celartem::TIFF6::getAsASCII | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a char array from the DataStore instance if the array type is TIFF6::ASCII. You can assume that the function does not throw any exceptions.
Please note that this function may return strings that contain non-ASCII characters if the original data contains them.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const u16* Celartem::TIFF6::getAsSHORT | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u16 array from the DataStore instance if the array type is TIFF6::SHORT. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const u32* Celartem::TIFF6::getAsLONG | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u32 array from the DataStore instance if the array type is TIFF6::LONG. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const TIFF_RATIONAL* Celartem::TIFF6::getAsRATIONAL | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a TIFF_RATIONAL array from the DataStore instance if the array type is TIFF6::RATIONAL. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const i8* Celartem::TIFF6::getAsSBYTE | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a i8 array from the DataStore instance if the array type is TIFF6::SBYTE. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const u8* Celartem::TIFF6::getAsUNDEFINED | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a u8 array from the DataStore instance if the array type is TIFF6::UNDEFINED. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL. | static const i16* Celartem::TIFF6::getAsSSHORT | ( | const DataStore * | inDataStore, | |
| const String & | inTag, | |||
| size_t * | outCount = NULL | |||
| ) | [static] |
This function returns the specified TIFF tag data as a i16 array from the DataStore instance if the array type is TIFF6::SSHORT. You can assume that the function does not throw any exceptions.
| inDataStore | The DataStore instance. | |
| inTag | The tag to search. | |
| outCount | Pointer to a size_t variable that receives the count of the data. It can be NULL if you don't need the count. |
NULL.