FreeImagePlus  - FreeImage 3.17.0
Public Member Functions | Protected Attributes | List of all members
fipTag Class Reference


FreeImage Tag More...

#include <FreeImagePlus.h>

Inheritance diagram for fipTag:
fipObject

Public Member Functions

 operator FITAG * ()
 
Returns a pointer to the FITAG data. More...
 
BOOL isValid () const
 Returns TRUE if the tag is allocated, FALSE otherwise. More...
 
const char * toString (FREE_IMAGE_MDMODEL model, char *Make=NULL) const
 
Converts a FreeImage tag structure to a string that represents the interpreted tag value More...
 
Creation & Destruction
 fipTag ()
 
Constructor More...
 
virtual ~fipTag ()
 
Destructor More...
 
BOOL setKeyValue (const char *key, const char *value)
 
Construct a FIDT_ASCII tag (ASCII string). More...
 
Copying
 fipTag (const fipTag &tag)
 
Copy constructor More...
 
fipTagoperator= (const fipTag &tag)
 
Copy constructor More...
 
fipTagoperator= (FITAG *tag)
 
Assignement operator
Copy the input pointer and manage its destruction More...
 
Tag accessors
const char * getKey () const
 
Returns the tag field name (unique inside a metadata model). More...
 
const char * getDescription () const
 
Returns the tag description if available, returns NULL otherwise More...
 
WORD getID () const
 
Returns the tag ID if available, returns 0 otherwise More...
 
FREE_IMAGE_MDTYPE getType () const
 
Returns the tag data type More...
 
DWORD getCount () const
 
Returns the number of components in the tag (in tag type units) More...
 
DWORD getLength () const
 
Returns the length of the tag value in bytes More...
 
const void * getValue () const
 
Returns the tag value More...
 
BOOL setKey (const char *key)
 
Set the tag field name More...
 
BOOL setDescription (const char *description)
 
Set the (usually optional) tag description More...
 
BOOL setID (WORD id)
 
Set the (usually optional) tad ID More...
 
BOOL setType (FREE_IMAGE_MDTYPE type)
 
Set the tag data type More...
 
BOOL setCount (DWORD count)
 
Set the number of data in the tag More...
 
BOOL setLength (DWORD length)
 
Set the length of the tag value, in bytes More...
 
BOOL setValue (const void *value)
 
Set the tag value More...
 
- Public Member Functions inherited from fipObject
virtual ~fipObject ()
 Destructor. More...
 

Protected Attributes

FITAG * _tag
 Pointer to a FreeImage tag. More...
 

Detailed Description


FreeImage Tag

FreeImage uses this structure to store metadata information.

Constructor & Destructor Documentation

◆ fipTag() [1/2]

fipTag::fipTag ( )


Constructor

See also
FreeImage_CreateTag

◆ ~fipTag()

virtual fipTag::~fipTag ( )
virtual


Destructor

See also
FreeImage_DeleteTag

◆ fipTag() [2/2]

fipTag::fipTag ( const fipTag tag)


Copy constructor

See also
FreeImage_CloneTag

Member Function Documentation

◆ getCount()

DWORD fipTag::getCount ( ) const


Returns the number of components in the tag (in tag type units)

See also
FreeImage_GetTagCount

◆ getDescription()

const char* fipTag::getDescription ( ) const


Returns the tag description if available, returns NULL otherwise

See also
FreeImage_GetTagDescription

◆ getID()

WORD fipTag::getID ( ) const


Returns the tag ID if available, returns 0 otherwise

See also
FreeImage_GetTagID

◆ getKey()

const char* fipTag::getKey ( ) const


Returns the tag field name (unique inside a metadata model).

See also
FreeImage_GetTagKey

◆ getLength()

DWORD fipTag::getLength ( ) const


Returns the length of the tag value in bytes

See also
FreeImage_GetTagLength

◆ getType()

FREE_IMAGE_MDTYPE fipTag::getType ( ) const


Returns the tag data type

See also
FreeImage_GetTagType

◆ getValue()

const void* fipTag::getValue ( ) const


Returns the tag value

See also
FreeImage_GetTagValue

◆ isValid()

BOOL fipTag::isValid ( ) const
virtual

Returns TRUE if the tag is allocated, FALSE otherwise.

Implements fipObject.

◆ operator FITAG *()

fipTag::operator FITAG * ( )
inline


Returns a pointer to the FITAG data.

Used for direct access from FREEIMAGE functions or from your own low level C functions.

See also
operator=(FITAG *tag)

◆ operator=() [1/2]

fipTag& fipTag::operator= ( const fipTag tag)


Copy constructor

See also
FreeImage_CloneTag

◆ operator=() [2/2]

fipTag& fipTag::operator= ( FITAG *  tag)


Assignement operator
Copy the input pointer and manage its destruction

See also
operator FITAG*()

◆ setCount()

BOOL fipTag::setCount ( DWORD  count)


Set the number of data in the tag

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagCount

◆ setDescription()

BOOL fipTag::setDescription ( const char *  description)


Set the (usually optional) tag description

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagDescription

◆ setID()

BOOL fipTag::setID ( WORD  id)


Set the (usually optional) tad ID

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagID

◆ setKey()

BOOL fipTag::setKey ( const char *  key)


Set the tag field name

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagKey

◆ setKeyValue()

BOOL fipTag::setKeyValue ( const char *  key,
const char *  value 
)


Construct a FIDT_ASCII tag (ASCII string).


This method is useful to store comments or IPTC tags.

Parameters
nameField name
valueField value
Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_CreateTag

◆ setLength()

BOOL fipTag::setLength ( DWORD  length)


Set the length of the tag value, in bytes

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagLength

◆ setType()

BOOL fipTag::setType ( FREE_IMAGE_MDTYPE  type)


Set the tag data type

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagType

◆ setValue()

BOOL fipTag::setValue ( const void *  value)


Set the tag value

Returns
Returns TRUE if successful, returns FALSE otherwise
See also
FreeImage_SetTagValue

◆ toString()

const char* fipTag::toString ( FREE_IMAGE_MDMODEL  model,
char *  Make = NULL 
) const


Converts a FreeImage tag structure to a string that represents the interpreted tag value

Parameters
modelMetadata model specification (metadata model from which the tag was extracted)
MakeCamera model (not used yet)

Member Data Documentation

◆ _tag

FITAG* fipTag::_tag
protected

Pointer to a FreeImage tag.


The documentation for this class was generated from the following file: