Mac OS 9
CGDirectPalette.h File Reference

xxx put contents here xxx More...

#include <CGDirectDisplay.h>

Go to the source code of this file.

Data Structures

struct  CGDeviceColor
 
struct  CGDeviceByteColor
 

Typedefs

typedef float CGPaletteBlendFraction
 
typedef struct CGDeviceColor CGDeviceColor
 
typedef struct CGDeviceByteColor CGDeviceByteColor
 

Functions

CGDirectPaletteRef CGPaletteCreateDefaultColorPalette (void)
 
CGDirectPaletteRef CGPaletteCreateWithDisplay (CGDirectDisplayID display)
 
CGDirectPaletteRef CGPaletteCreateWithCapacity (CGTableCount capacity)
 
CGDirectPaletteRef CGPaletteCreateWithSamples (CGDeviceColor *sampleTable, CGTableCount sampleCount)
 
CGDirectPaletteRef CGPaletteCreateWithByteSamples (CGDeviceByteColor *sampleTable, CGTableCount sampleCount)
 
void CGPaletteRelease (CGDirectPaletteRef palette)
 
CGDeviceColor CGPaletteGetColorAtIndex (CGDirectPaletteRef palette, CGTableCount index)
 
CGTableCount CGPaletteGetIndexForColor (CGDirectPaletteRef palette, CGDeviceColor color)
 
CGTableCount CGPaletteGetNumberOfSamples (CGDirectPaletteRef palette)
 
void CGPaletteSetColorAtIndex (CGDirectPaletteRef palette, CGDeviceColor color, CGTableCount index)
 
CGDirectPaletteRef CGPaletteCreateCopy (CGDirectPaletteRef palette)
 
Boolean CGPaletteIsEqualToPalette (CGDirectPaletteRef palette1, CGDirectPaletteRef palette2)
 
CGDirectPaletteRef CGPaletteCreateFromPaletteBlendedWithColor (CGDirectPaletteRef palette, CGPaletteBlendFraction fraction, CGDeviceColor color)
 

Detailed Description

xxx put contents here xxx

Introduced In: from CoreGraphics-70.root
Avaliable From: Universal Interfaces 3.4.1
Copyright: � 2000-2001 by Apple Computer, Inc., all rights reserved.

For bug reports, consult the following page on the World Wide Web:

http://developer.apple.com/bugreporter/

Function Documentation

◆ CGPaletteCreateCopy()

CGDirectPaletteRef CGPaletteCreateCopy ( CGDirectPaletteRef  palette)

Copy a palette CGPaletteCreateCopy()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateDefaultColorPalette()

CGDirectPaletteRef CGPaletteCreateDefaultColorPalette ( void  )

Create a new palette object representing the default 8 bit color palette. Release the palette using CGPaletteRelease(). CGPaletteCreateDefaultColorPalette()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateFromPaletteBlendedWithColor()

CGDirectPaletteRef CGPaletteCreateFromPaletteBlendedWithColor ( CGDirectPaletteRef  palette,
CGPaletteBlendFraction  fraction,
CGDeviceColor  color 
)

Create a new palette blended with a fraction of a device color. Free the resulting palette with CGPaletteRelease() CGPaletteCreateFromPaletteBlendedWithColor()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateWithByteSamples()

CGDirectPaletteRef CGPaletteCreateWithByteSamples ( CGDeviceByteColor sampleTable,
CGTableCount  sampleCount 
)

Convenience function: Create a new palette with a capacity and contents as specified. Release the palette using CGPaletteRelease(). CGPaletteCreateWithByteSamples()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateWithCapacity()

CGDirectPaletteRef CGPaletteCreateWithCapacity ( CGTableCount  capacity)

Create a new palette with a capacity as specified. Entries are initialized from the default color palette. Release the palette using CGPaletteRelease(). CGPaletteCreateWithCapacity()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateWithDisplay()

CGDirectPaletteRef CGPaletteCreateWithDisplay ( CGDirectDisplayID  display)

Create a copy of the display's current palette, if any. Returns NULL if the current display mode does not support a palette. Release the palette using CGPaletteRelease(). CGPaletteCreateWithDisplay()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteCreateWithSamples()

CGDirectPaletteRef CGPaletteCreateWithSamples ( CGDeviceColor sampleTable,
CGTableCount  sampleCount 
)

Create a new palette with a capacity and contents as specified. Release the palette using CGPaletteRelease(). CGPaletteCreateWithSamples()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteGetColorAtIndex()

CGDeviceColor CGPaletteGetColorAtIndex ( CGDirectPaletteRef  palette,
CGTableCount  index 
)

Get the color value at the specified index CGPaletteGetColorAtIndex()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteGetIndexForColor()

CGTableCount CGPaletteGetIndexForColor ( CGDirectPaletteRef  palette,
CGDeviceColor  color 
)

Get the index for the specified color value The index returned is for a palette color with the lowest RMS error to the specified color. CGPaletteGetIndexForColor()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteGetNumberOfSamples()

CGTableCount CGPaletteGetNumberOfSamples ( CGDirectPaletteRef  palette)

Get the number of samples in the palette CGPaletteGetNumberOfSamples()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteIsEqualToPalette()

Boolean CGPaletteIsEqualToPalette ( CGDirectPaletteRef  palette1,
CGDirectPaletteRef  palette2 
)

Compare two palettes CGPaletteIsEqualToPalette()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteRelease()

void CGPaletteRelease ( CGDirectPaletteRef  palette)

Release a palette CGPaletteRelease()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later

◆ CGPaletteSetColorAtIndex()

void CGPaletteSetColorAtIndex ( CGDirectPaletteRef  palette,
CGDeviceColor  color,
CGTableCount  index 
)

Set the color value at the specified index CGPaletteSetColorAtIndex()

Availability:

Non-Carbon CFM: not available
Carbon Lib: not available
Mac OS X: in version 10.0 and later