Constructors & DestructorUse these functions to create and destroy instances of this class.
![]() |
public:
virtual ~IColorMap()
Destroy a color map instance.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
Construct a color map object.
public:
IColorMap(const IColorMap&)
Copy constructor.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IColorMap(EColorMapType colorMapType = kUserDefined)
Constructs a color map of the specified map type. The default map type is kUserDefined.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IColorMap(unsigned long, const IR8G8B8A8Color*)
Constructs a color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IColorMap(unsigned long numberOfColors = 256)
Constructs a color map with the specified number of colors. The default is 256 colors.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
public:
IColorMap(IRGBAColorArray* colorArrayToAdopt)
Constructs a color map with a color array. Accepts a pointer to the color array.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
Accessing the Color DataUse these functions to access and manipulate the color data.
![]() |
public:
unsigned long colorIndex(const IBaseColor&) const
Returns the index of a color in the color map.
| IGraphicException | if the index is invalid |
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static bool hasColorMapSupport()
Returns true if the system supports colormaps.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
bool isColorIndexAllocated(unsigned long index) const
Returns true if the color index is allocated.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
virtual bool isSystemColor(unsigned long) const
Tests whether a color is a system color and returns true if the color is a system color.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
unsigned long mapColors( unsigned long, const IR8G8B8A8Color* )
Map colors into the color array.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
unsigned long numberOfColors() const
Returns the size of the color array.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
const IR8G8B8A8Color& operator [](unsigned long) const
Index of operator to access the colors within the data structure.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
unsigned long releaseCells()
Release all cells other than Reserved cells. Returns the number of released cells.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
virtual void setColor(unsigned long i, const IBaseColor& p)
| IGraphicException | if the index is invalid |
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static unsigned long systemColorIndex(const IBaseColor&)
Get the index of a color in the system color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static unsigned long systemColorRGB(const long)
Get the rgb value of a color in the system color map, given the index.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
Assignment and Equality OperatorsUse this operator function to handle color array assignment and equality tests.
![]() |
public:
IColorMap& operator =(const IColorMap&)
Assignment operator. Returns a non-constant reference to the left hand side object.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
virtual bool operator ==(const IColorMap&) const
Tests the two color arrays for equality.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
Color Array OwnershipUse these functions to adopt and relinquish control of a color data array.
![]() |
public:
virtual void adoptColorArray( unsigned long size, IR8G8B8A8Color* colorArrayToAdopt )
Accept ownership of a color array.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
virtual IR8G8B8A8Color* orphanColorArray()
Relinquishes knowledge of, and responsibility for, the color array and returns it to the caller. Returns a pointer to the color array data that was orphaned.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
Streaming SupportUse these functions to enable streaming of color maps.
![]() |
public:
IDataStream& operator <<=(IDataStream&)
This function supports streaming in the color map data.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
IDataStream& operator >>=(IDataStream&) const
This function supports streaming out the color map data.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
Using Color MapsUse these functions to work with various types of color maps for the underlying platform.
![]() |
public:
EColorMapType colorMapType() const
Return the type of the color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static IColorMap& defaultColorMap()
Returns a reference to a default system color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static IColorMap& defaultSystemColorMap()
Returns a reference to a default system color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
unsigned long nativeColorMap()
Creates a platform specific native palette using IRGBAColorArray data. Returns the native palette being created.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
void setColorMapType(EColorMapType)
Set the color map type to one of the values in EColorMapType.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static void setDefaultColorMap(IColorMap*)
Sets the default color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static IColorMap& trueColorMap()
Returns a reference to a default true color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
public:
static IColorMap& webSafeColorMap()
Returns a reference to a default web-safe color map.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
enum EColorCellStatus { kNotFound=-,
kReserved=0,
kFree=1,
kUsed=2 }The status of cells in the color array.
| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
![]() |
enum EColorMapType { kSystem=-,
kTrueColor=0,
kUserDefined=1 }| Windows | OS/2 | AIX |
| Yes | Yes | Yes |
virtual ~IRGBAColorArray()
IBaseColor color(unsigned long i) const
IRGBAColorArray(unsigned long numberOfColors = 256)
IRGBAColorArray(const IRGBAColorArray& source)
IDataStream& operator <<=(IDataStream& fromWhere)
IRGBAColorArray& operator =(const IRGBAColorArray& Src)
virtual bool operator ==(const IRGBAColorArray&) const
IDataStream& operator >>=(IDataStream& toWhere) const
const IR8G8B8A8Color& operator [](unsigned long i) const
IR8G8B8A8Color& operator [](unsigned long i)