public class Color4f extends Tuple4f implements Serializable
Java 3D assumes that a linear (gamma-corrected) visual is used for all colors.
Constructor and Description |
---|
Color4f()
Constructs and initializes a Color4f to (0.0, 0.0, 0.0, 0.0).
|
Color4f(Color color)
Constructs and initializes a Color4f from the specified AWT
Color object.
|
Color4f(Color4f c1)
Constructs and initializes a Color4f from the specified Color4f.
|
Color4f(float[] c)
Constructs and initializes a Color4f from the array of length 4.
|
Color4f(float x,
float y,
float z,
float w)
Constructs and initializes a Color4f from the specified xyzw
coordinates.
|
Color4f(Tuple4d t1)
Constructs and initializes a Color4f from the specified Tuple4d.
|
Color4f(Tuple4f t1)
Constructs and initializes a Color4f from the specified Tuple4f.
|
Modifier and Type | Method and Description |
---|---|
Color |
get()
Returns a new AWT color object initialized with the r,g,b,a
values of this Color4f object.
|
void |
set(Color color)
Sets the r,g,b,a values of this Color4f object to those of the
specified AWT Color object.
|
absolute, absolute, add, add, clamp, clamp, clampMax, clampMax, clampMin, clampMin, clone, epsilonEquals, equals, equals, get, get, getW, getX, getY, getZ, hashCode, interpolate, interpolate, negate, negate, scale, scale, scaleAdd, scaleAdd, set, set, set, set, setW, setX, setY, setZ, sub, sub, toString
public Color4f(float x, float y, float z, float w)
x
- the red color valuey
- the green color valuez
- the blue color valuew
- the alpha valuepublic Color4f(float[] c)
c
- the array of length 4 containing r,g,b,a in orderpublic Color4f(Color4f c1)
c1
- the Color4f containing the initialization r,g,b,a datapublic Color4f(Tuple4f t1)
t1
- the Tuple4f containing the initialization r,g,b,a datapublic Color4f(Tuple4d t1)
t1
- the Tuple4d containing the initialization r,g,b,a datapublic Color4f(Color color)
color
- the AWT color with which to initialize this
Color4f objectpublic Color4f()
public final void set(Color color)
color
- the AWT color to copy into this Color4f objectpublic final Color get()
Copyright © 2016–2022 SciJava. All rights reserved.