|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Color
com.threed.jpct.RGBColor
Mimics the Color-class in java.awt just like jPCT-AE does it. This class should help to ease porting applications to jPCT-AE (the Android version of jPCT).
| Field Summary | |
static RGBColor |
BLACK
|
static RGBColor |
BLUE
|
static RGBColor |
GREEN
|
static RGBColor |
RED
|
static RGBColor |
WHITE
|
| Fields inherited from class java.awt.Color |
black, blue, cyan, CYAN, DARK_GRAY, darkGray, gray, GRAY, green, LIGHT_GRAY, lightGray, magenta, MAGENTA, orange, ORANGE, pink, PINK, red, white, yellow, YELLOW |
| Fields inherited from interface java.awt.Transparency |
BITMASK, OPAQUE, TRANSLUCENT |
| Constructor Summary | |
RGBColor()
Creates a new, black color. |
|
RGBColor(int r,
int g,
int b)
Creates a new color. |
|
RGBColor(int r,
int g,
int b,
int a)
Creates a new color with alpha. |
|
| Method Summary | |
int |
getAlpha()
Returns the alpha value (0..255). |
int |
getARGB()
Returns the color as an int argb value with alpha. |
int |
getBlue()
Returns the blue value (0..255). |
int |
getGreen()
Returns the green value (0..255). |
float |
getNormalizedAlpha()
Returns the alpha value in normalized form (0..1). |
float |
getNormalizedBlue()
Returns the blue value in normalized form (0..1). |
float |
getNormalizedGreen()
Returns the green value in normalized form (0..1). |
float |
getNormalizedRed()
Returns the red value in normalized form (0..1). |
int |
getRed()
Returns the red value (0..255). |
int |
getRGB()
Returns the color as an int rgb value. |
| Methods inherited from class java.awt.Color |
brighter, createContext, darker, decode, equals, getColor, getColor, getColor, getColorComponents, getColorComponents, getColorSpace, getComponents, getComponents, getHSBColor, getRGBColorComponents, getRGBComponents, getTransparency, hashCode, HSBtoRGB, RGBtoHSB, toString |
| Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
| Field Detail |
public static final RGBColor BLACK
public static final RGBColor WHITE
public static final RGBColor RED
public static final RGBColor GREEN
public static final RGBColor BLUE
| Constructor Detail |
public RGBColor()
public RGBColor(int r,
int g,
int b)
r - red value between 0 and 255g - green value between 0 and 255b - blue value between 0 and 255
public RGBColor(int r,
int g,
int b,
int a)
r - red value between 0 and 255g - green value between 0 and 255b - blue value between 0 and 255a - alpha value between 0 and 255| Method Detail |
public float getNormalizedRed()
public float getNormalizedGreen()
public float getNormalizedBlue()
public float getNormalizedAlpha()
public int getRed()
public int getBlue()
public int getGreen()
public int getAlpha()
public int getRGB()
public int getARGB()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||