|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.eclipse.swt.graphics.PaletteData
Unsafe:
Field Summary | |
int |
blueMask
Suppressed: the blue mask for a direct palette |
int |
blueShift
Suppressed: the blue shift for a direct palette |
RGB[] |
colors
Suppressed: the RGB values for an indexed palette, where the indices of the array correspond to pixel values |
int |
greenMask
Suppressed: the green mask for a direct palette |
int |
greenShift
Suppressed: the green shift for a direct palette |
boolean |
isDirect
Suppressed: true if the receiver is a direct palette, and false otherwise |
int |
redMask
Suppressed: the red mask for a direct palette |
int |
redShift
Suppressed: the red shift for a direct palette |
Constructor Summary | |
PaletteData(int redMask,
int greenMask,
int blueMask)
Suppressed: Constructs a new direct palette given the red, green and blue masks. |
|
PaletteData(RGB[] colors)
Suppressed: Constructs a new indexed palette given an array of RGB values. |
Method Summary | |
int |
getPixel(RGB rgb)
Suppressed: Returns the pixel value corresponding to the given RBG . |
RGB |
getRGB(int pixel)
Suppressed: Returns an RGB corresponding to the given pixel value. |
RGB[] |
getRGBs()
Suppressed: Returns all the RGB values in the receiver if it is an indexed palette, or null if it is a direct palette. |
(package private) int |
shiftForMask(int mask)
Computes the shift value for a given mask. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public boolean isDirect
public RGB[] colors
public int redMask
public int greenMask
public int blueMask
public int redShift
public int greenShift
public int blueShift
Constructor Detail |
public PaletteData(RGB[] colors)
colors
- the array of RGB
s for the palettepublic PaletteData(int redMask, int greenMask, int blueMask)
redMask
- the red maskgreenMask
- the green maskblueMask
- the blue maskMethod Detail |
public int getPixel(RGB rgb)
RBG
.
public RGB getRGB(int pixel)
RGB
corresponding to the given pixel value.
public RGB[] getRGBs()
RGB
s for the receiver or nullint shiftForMask(int mask)
mask
- the mask to compute the shift for
PaletteData
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |