public class Color
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static Color |
BLACK |
static Color |
NONE |
int |
rgba |
static Color |
WHITE |
Constructor and Description |
---|
Color(Color other)
Copy constructor.
|
Color(int rgba)
Constructor.
|
Color(int r,
int g,
int b,
float a)
Constructor.
|
Color(int r,
int g,
int b,
int a)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
float |
a_f()
Returns the normalised aslpha channel value.
|
int |
a()
Returns the alpha channel value.
|
float |
b_f()
Returns the normalised blue channel value.
|
int |
b()
Returns the blue channel value.
|
boolean |
equals(java.lang.Object obj) |
float |
g_f()
Returns the normalised green channel value.
|
int |
g()
Returns the green channel value.
|
int |
hashCode() |
float |
r_f()
Returns the normalised red channel value.
|
int |
r()
Returns the red channel value.
|
java.lang.String |
toString() |
public final int rgba
public static final Color NONE
public static final Color BLACK
public static final Color WHITE
public Color(Color other)
other
- copied object.public Color(int rgba)
rgba
- the color value packed as 32bit.public Color(int r, int g, int b, int a)
r
- the red channel value (= 0..255).g
- the green channel value (= 0..255).b
- the blue channel value (= 0..255).a
- the alpha channel value (= 0..255).public Color(int r, int g, int b, float a)
r
- the red channel value (= 0..255).g
- the green channel value (= 0..255).b
- the blue channel value (= 0..255).a
- the alpha channel value (= 0..1).public final int r()
public final int g()
public final int b()
public final int a()
public final float r_f()
public final float g_f()
public final float b_f()
public final float a_f()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public final int hashCode()
hashCode
in class java.lang.Object
public final java.lang.String toString()
toString
in class java.lang.Object