|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectapps.lightrays.raytracer.scene.Colour
public class Colour
The Class Colour.
| Field Summary | |
|---|---|
double |
b
The b. |
double |
g
The g. |
double |
r
The r. |
| Constructor Summary | |
|---|---|
Colour()
Instantiates a new colour. |
|
Colour(Colour c)
Instantiates a new colour. |
|
Colour(double r,
double g,
double b)
Instantiates a new colour. |
|
Colour(int rgb)
Instantiates a new colour. |
|
| Method Summary | |
|---|---|
void |
attenuate(Colour c)
Attenuate. |
void |
attenuate(double a)
Attenuate. |
void |
combineWith(Colour c)
Combine with. |
static Colour |
getAverageColour(Colour[] array)
Gets the average colour. |
int |
getRGB()
Gets the rgb. |
void |
set(Colour c)
Sets the. |
void |
set(double r,
double g,
double b)
Sets the. |
java.lang.String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public double b
public double g
public double r
| Constructor Detail |
|---|
public Colour()
public Colour(Colour c)
c - the c
public Colour(double r,
double g,
double b)
r - the rg - the gb - the bpublic Colour(int rgb)
rgb - the rgb| Method Detail |
|---|
public static Colour getAverageColour(Colour[] array)
array - the array
public final void attenuate(Colour c)
c - the cpublic final void attenuate(double a)
a - the apublic final void combineWith(Colour c)
c - the cpublic final int getRGB()
public void set(Colour c)
c - the c
public void set(double r,
double g,
double b)
r - the rg - the gb - the bpublic java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||