SampleICC Main srcforge
Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

CIccTagNamedColor2 Class Reference

#include <IccTagBasic.h>

Inheritance diagram for CIccTagNamedColor2:

CIccTag List of all members.

Public Member Functions

 CIccTagNamedColor2 (int nSize=1, int nDeviceCoords=0)
 CIccTagNamedColor2 (const CIccTagNamedColor2 &ITNC)
CIccTagNamedColor2operator= (const CIccTagNamedColor2 &NamedColor2Tag)
virtual CIccTagNewCopy () const
virtual ~CIccTagNamedColor2 ()
virtual icTagTypeSignature GetType ()
virtual const icCharGetClassName ()
virtual bool UseLegacyPCS ()
virtual void Describe (std::string &sDescription)
virtual bool Read (icUInt32Number size, CIccIO *pIO)
virtual bool Write (CIccIO *pIO)
const icCharGetPrefix () const
void SetPrefix (const icChar *szPrefix)
const icCharGetSufix () const
void SetSufix (const icChar *szSufix)
icUInt32Number GetVendorFlags () const
void SetVendorFlags (icUInt32Number nVendorFlags)
icInt32Number FindColor (const icChar *szColor)
icInt32Number FindRootColor (const icChar *szRootColor)
icInt32Number FindPCSColor (icFloatNumber *pPCS, icFloatNumber dMinDE=1000.0)
icInt32Number FindDeviceColor (icFloatNumber *pDevColor)
void ResetPCSCache ()
 Call ResetPCSCache() if entry values change between calls to FindPCSColor().
bool GetColorName (std::string &sColorName, icInt32Number index)
SIccNamedColorEntryoperator[] (icUInt32Number index)
SIccNamedColorEntryGetEntry (icUInt32Number index)
icUInt32Number GetSize () const
icUInt32Number GetDeviceCoords () const
void SetSize (icUInt32Number nSize, icInt32Number nDeviceCoords=-1)
virtual void SetColorSpaces (icColorSpaceSignature csPCS, icColorSpaceSignature csDevice)
icColorSpaceSignature GetPCS () const
icColorSpaceSignature GetDeviceSpace () const
icFloatNumber NegClip (icFloatNumber v)
icFloatNumber UnitClip (icFloatNumber v)
void Lab2ToLab4 (icFloatNumber *Dst, const icFloatNumber *Src)
void Lab4ToLab2 (icFloatNumber *Dst, const icFloatNumber *Src)
virtual icValidateStatus Validate (icTagSignature sig, std::string &sReport, const CIccProfile *pProfile=NULL) const

Protected Attributes

icChar m_szPrefix [32]
icChar m_szSufix [32]
SIccNamedColorEntrym_NamedColor
SIccNamedLabEntrym_NamedLab
icUInt32Number m_nColorEntrySize
 For quick response of repeated FindPCSColor.
icUInt32Number m_nVendorFlags
icUInt32Number m_nDeviceCoords
icUInt32Number m_nSize
icColorSpaceSignature m_csPCS
icColorSpaceSignature m_csDevice

Detailed Description

Class: CIccTagNamedColor2

Purpose: the NamedColor2 tag - an array of Named Colors


Constructor & Destructor Documentation

CIccTagNamedColor2::CIccTagNamedColor2 int  nSize = 1,
int  nDeviceCoords = 0
 

Name: CIccTagNamedColor2::CIccTagNamedColor2

Purpose: Constructor

Args: nSize = number of named color entries, nDeviceCoords = number of device channels

CIccTagNamedColor2::CIccTagNamedColor2 const CIccTagNamedColor2 ITNC  ) 
 

Name: CIccTagNamedColor2::CIccTagNamedColor2

Purpose: Copy Constructor

Args: ITNC = The CIccTagNamedColor2 object to be copied

CIccTagNamedColor2::~CIccTagNamedColor2  )  [virtual]
 

Name: CIccTagNamedColor2::~CIccTagNamedColor2

Purpose: Destructor


Member Function Documentation

void CIccTagNamedColor2::Describe std::string &  sDescription  )  [virtual]
 

Name: CIccTagNamedColor2::Describe

Purpose: Dump data associated with the tag to a string

Args: sDescription - string to concatenate tag dump to

Reimplemented from CIccTag.

icInt32Number CIccTagNamedColor2::FindColor const icChar szColor  ) 
 

Name: CIccTagNamedColor2::FindColor

Purpose: Find the color with given name

Args: szColor = the color name

Return: Index of the named color array where the color name was found, if the color was not found -1 is returned

icInt32Number CIccTagNamedColor2::FindDeviceColor icFloatNumber pDevColor  ) 
 

Name: CIccTagNamedColor2::FindColor

Purpose: Find the device color

Args: pDevColor = device color co-ordinates

Return: Index of the named color array where the closest device color was found, if device representation is absent -1 is returned.

icInt32Number CIccTagNamedColor2::FindPCSColor icFloatNumber pPCS,
icFloatNumber  dMinDE = 1000.0
 

Name: CIccTagNamedColor2::FindPCSColor

Purpose: Find the PCS color within the specified deltaE

Args: pPCS = PCS co-ordinates, dMinDE = the minimum deltaE (tolerance)

Return: Index of the named color array where the PCS color was found, if the color was not found within the tolerance -1 is returned

icInt32Number CIccTagNamedColor2::FindRootColor const icChar szRootColor  ) 
 

Name: CIccTagNamedColor2::FindRootColor

Purpose: Find the root color name

Args: szRootColor = string containing the root color name to be found

Return: Index of the named color array where the root color name was found, if the color was not found -1 is returned

virtual const icChar* CIccTagNamedColor2::GetClassName  )  [inline, virtual]
 

Reimplemented from CIccTag.

bool CIccTagNamedColor2::GetColorName std::string &  sColorName,
icInt32Number  index
 

Name: CIccTagNamedColor2::GetColorName

Purpose: Extracts the color name from the named color array

Args: sColorName = string where color name will be stored, index = array index of the color name

Return: true = if the index is within range, false = index out of range

icUInt32Number CIccTagNamedColor2::GetDeviceCoords  )  const [inline]
 

icColorSpaceSignature CIccTagNamedColor2::GetDeviceSpace  )  const [inline]
 

SIccNamedColorEntry* CIccTagNamedColor2::GetEntry icUInt32Number  index  )  [inline]
 

icColorSpaceSignature CIccTagNamedColor2::GetPCS  )  const [inline]
 

const icChar* CIccTagNamedColor2::GetPrefix  )  const [inline]
 

icUInt32Number CIccTagNamedColor2::GetSize  )  const [inline]
 

const icChar* CIccTagNamedColor2::GetSufix  )  const [inline]
 

virtual icTagTypeSignature CIccTagNamedColor2::GetType  )  [inline, virtual]
 

Function: GetType()

Purpose: Get Tag Type. Each derived tag will implement it's own GetType() function.

Reimplemented from CIccTag.

icUInt32Number CIccTagNamedColor2::GetVendorFlags  )  const [inline]
 

void CIccTagNamedColor2::Lab2ToLab4 icFloatNumber Dst,
const icFloatNumber Src
 

Name: CIccTagNamedColor2::Lab2ToLab4

Purpose: Convert version 2 Lab to version 4 Lab

Args: Dst = array to store version 4 Lab coordinates, Src = array containing version 2 Lab coordinates

void CIccTagNamedColor2::Lab4ToLab2 icFloatNumber Dst,
const icFloatNumber Src
 

Name: CIccTagNamedColor2::Lab4ToLab2

Purpose: Convert version 4 Lab to version 2 Lab

Args: Dst = array to store version 2 Lab coordinates, Src = array containing version 4 Lab coordinates

icFloatNumber CIccTagNamedColor2::NegClip icFloatNumber  v  ) 
 

Name: CIccTagNamedColor2::NegClip

Purpose: Negative numbers are clipped to zero

Args: v = number to be clipped

Return: Clipped number

virtual CIccTag* CIccTagNamedColor2::NewCopy  )  const [inline, virtual]
 

Function: NewCopy(sDescription) Each derived tag will implement it's own NewCopy() function.

Parameter(s): none

Returns a new CIccTag object that is a copy of this object.

Reimplemented from CIccTag.

CIccTagNamedColor2 & CIccTagNamedColor2::operator= const CIccTagNamedColor2 NamedColor2Tag  ) 
 

Name: CIccTagNamedColor2::operator=

Purpose: Copy Operator

Args: NamedColor2Tag = The CIccTagNamedColor2 object to be copied

SIccNamedColorEntry& CIccTagNamedColor2::operator[] icUInt32Number  index  )  [inline]
 

bool CIccTagNamedColor2::Read icUInt32Number  size,
CIccIO pIO
[virtual]
 

Name: CIccTagNamedColor2::Read

Purpose: Read in the tag contents into a data block

Args: size - # of bytes in tag, pIO - IO object to read tag from

Return: true = successful, false = failure

Reimplemented from CIccTag.

void CIccTagNamedColor2::ResetPCSCache  ) 
 

Call ResetPCSCache() if entry values change between calls to FindPCSColor().

Name: CIccTagNamedColor2::ResetPCSCache

Purpose: This function is called if entry values change between calls to FindPCSColor()

void CIccTagNamedColor2::SetColorSpaces icColorSpaceSignature  csPCS,
icColorSpaceSignature  csDevice
[virtual]
 

Name: CIccTagNamedColor2::SetColorSpaces

Purpose: Set the device and PCS color space of the tag

Args: csPCS = PCS color space signature, csDevice = Device color space signature

void CIccTagNamedColor2::SetPrefix const icChar szPrefix  ) 
 

void CIccTagNamedColor2::SetSize icUInt32Number  nSize,
icInt32Number  nDeviceCoords = -1
 

Name: CIccTagNamedColor2::SetSize

Purpose: Sets the size of the named color array.

Args: nSize - number of named color entries, nDeviceCoords - number of device channels

void CIccTagNamedColor2::SetSufix const icChar szSufix  ) 
 

void CIccTagNamedColor2::SetVendorFlags icUInt32Number  nVendorFlags  )  [inline]
 

icFloatNumber CIccTagNamedColor2::UnitClip icFloatNumber  v  ) 
 

Name: CIccTagNamedColor2::UnitClip

Purpose: Clip number so that its between 0-1

Args: v = number to be clipped

Return: Clipped number

virtual bool CIccTagNamedColor2::UseLegacyPCS  )  [inline, virtual]
 

icValidateStatus CIccTagNamedColor2::Validate icTagSignature  sig,
std::string &  sReport,
const CIccProfile pProfile = NULL
const [virtual]
 

Name: CIccTagNamedColor2::Validate

Purpose: Check tag data validity.

Args: sig = signature of tag being validated, sReport = String to add report information to

Return: icValidateStatusOK if valid, or other error status.

Reimplemented from CIccTag.

bool CIccTagNamedColor2::Write CIccIO pIO  )  [virtual]
 

Name: CIccTagNamedColor2::Write

Purpose: Write the tag to a file

Args: pIO - The IO object to write tag to.

Return: true = succesful, false = failure

Reimplemented from CIccTag.


Member Data Documentation

icColorSpaceSignature CIccTagNamedColor2::m_csDevice [protected]
 

icColorSpaceSignature CIccTagNamedColor2::m_csPCS [protected]
 

SIccNamedColorEntry* CIccTagNamedColor2::m_NamedColor [protected]
 

SIccNamedLabEntry* CIccTagNamedColor2::m_NamedLab [protected]
 

icUInt32Number CIccTagNamedColor2::m_nColorEntrySize [protected]
 

For quick response of repeated FindPCSColor.

icUInt32Number CIccTagNamedColor2::m_nDeviceCoords [protected]
 

icUInt32Number CIccTagNamedColor2::m_nSize [protected]
 

icUInt32Number CIccTagNamedColor2::m_nVendorFlags [protected]
 

icChar CIccTagNamedColor2::m_szPrefix[32] [protected]
 

icChar CIccTagNamedColor2::m_szSufix[32] [protected]
 


The documentation for this class was generated from the following files:
Generated on Tue Jun 26 17:51:46 2007 for IccProfLib by  doxygen 1.3.9.1