javax.vecmath

Class Color3f

Implemented Interfaces:
Serializable

public class Color3f
extends Tuple3f
implements Serializable

A 3 element color represented by single precision floating point x,y,z coordinates. Color components should be in the range of zero to one.
Version:
specification 1.2, implementation $Revision: 1.9 $, $Date: 1999/11/25 10:55:01 $
Author:
Kenji hiranabe

Field Summary

Fields inherited from class javax.vecmath.Tuple3f

x, y, z

Constructor Summary

Color3f()
Constructs and initializes a Color3f to (0,0,0).
Color3f(c[] )
Constructs and initializes a Color3f from input array of length 3.
Color3f(float x, float y, float z)
Constructs and initializes a Color3f from the specified xyz
Color3f(java.awt.Color color)
Constructs color from awt.Color.
Color3f(Color3f c1)
Constructs and initializes a Color3f from the specified Color3f.
Color3f(Tuple3d t1)
Constructs and initializes a Color3f from the specified Tuple3d.
Color3f(Tuple3f t1)
Constructs and initializes a Color3f from the specified Tuple3f.

Method Summary

java.awt.Color
get()
Gets awt.Color.
void
set(java.awt.Color color)
Sets color from awt.Color.

Methods inherited from class javax.vecmath.Tuple3f

absolute, absolute, add, add, clamp, clamp, clampMax, clampMax, clampMin, clampMin, epsilonEquals, equals, get, get, hashCode, interpolate, interpolate, negate, negate, scale, scale, scaleAdd, scaleAdd, set, set, set, set, sub, sub, toString

Constructor Details

Color3f

public Color3f()
Constructs and initializes a Color3f to (0,0,0).

Color3f

public Color3f(c[] )
Constructs and initializes a Color3f from input array of length 3.
Parameters:

Color3f

public Color3f(float x,
               float y,
               float z)
Constructs and initializes a Color3f from the specified xyz
Parameters:
x - the x coordinate
y - the y coordinate
z - the z coordinate

Color3f

public Color3f(java.awt.Color color)
Constructs color from awt.Color.
Parameters:
color - awt color

Color3f

public Color3f(Color3f c1)
Constructs and initializes a Color3f from the specified Color3f.
Parameters:

Color3f

public Color3f(Tuple3d t1)
Constructs and initializes a Color3f from the specified Tuple3d.
Parameters:
t1 - the Tuple3d containing the initialization x y z data

Color3f

public Color3f(Tuple3f t1)
Constructs and initializes a Color3f from the specified Tuple3f.
Parameters:
t1 - the Tuple3f containing the initialization x y z data

Method Details

get

public final java.awt.Color get()
Gets awt.Color.
Returns:
color awt color

set

public final void set(java.awt.Color color)
Sets color from awt.Color.
Parameters:
color - awt color