|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.grogra.vecmath.geom.Line
public class Line
This class represents the geometry of a line.
Field Summary | |
---|---|
Vector3d |
direction
Specifies the direction of the line. |
float |
directionDensity
The probability density of direction for this ray. |
double |
end
The line ends at origin + end * direction . |
Tuple3d |
origin
Origin of the line. |
float |
originDensity
The probability density of origin for this ray. |
boolean |
reflected
|
Color3f |
spectrum
The spectrum of the ray. |
double |
start
The line starts at origin + start * direction . |
boolean |
valid
|
float |
x
|
float |
y
|
Constructor Summary | |
---|---|
Line()
|
|
Line(Tuple3d origin,
Vector3d direction,
double start,
double end)
|
Method Summary | |
---|---|
Line |
deepCopy()
|
double |
distance(Tuple3d point)
Computes the distance between point and this line. |
double |
distanceSquared(Tuple3d point)
Computes the square of the distance between point and this line. |
double |
length()
Returns the length of this line. |
double |
lengthSquared()
Returns the square of the length of this line. |
void |
setLineAttributes(double start,
double end)
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public Vector3d direction
public float directionDensity
Shader.generateRandomRays
and
Light.generateRandomRays
.
If pω+ is the probability density
that has been used for generating the random ray direction
(measured with respect to projected solid angle ω+, i.e.,
dω+ = cos θ dω),
then this field is set to
pω+(direction
). It is not
defined for rays emanating from a directional light source. It
may be Float.POSITIVE_INFINITY
as a result of
Shader.generateRandomRays
, namely
for ideal specular reflection or transmission.
public double end
origin + end * direction
.
The condition start <= end
has to be satisfied.
public Tuple3d origin
public float originDensity
Light.generateRandomRays
.
If px is the probability density
that has been used for generating the random ray origin,
then this field is set to
px(origin
). It is not
defined for rays emanating from a point light source.
public boolean reflected
public Color3f spectrum
public double start
origin + start * direction
.
public boolean valid
public float x
public float y
Constructor Detail |
---|
public Line()
public Line(Tuple3d origin, Vector3d direction, double start, double end)
Method Detail |
---|
public Line deepCopy()
public double distance(Tuple3d point)
point
and this line. The distance
is defined to be the distance between
point
and the closest point of this line.
point
- a point
point
public double distanceSquared(Tuple3d point)
point
and this line. The distance
is defined to be the distance between
point
and the closest point of this line.
point
- a point
point
public double length()
public double lengthSquared()
public void setLineAttributes(double start, double end)
public 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 |