| Modifier and Type | Field and Description |
|---|---|
| private int | hash
Cache the hash code to make computing hashes faster. |
| private final double | x
The x coordinate. |
| private final double | y
The y coordinate. |
| private final double | z
The z coordinate. |
| public static final Point3D | ZERO
Point or vector with all three coordinates set to 0. |
| Access | Constructor and Description |
|---|---|
| public | Point3D(double
The X coordinate of the x, double Point3DThe Y coordinate of the y, double Point3DThe Z coordinate of the z)Point3DCreates a new instance of |
| Modifier and Type | Method and Description |
|---|---|
| public Point3D | Returns: the point with added coordinatesthe X coordinate addition x, double the Y coordinate addition y, double the Z coordinate addition z)Returns a point with the specified coordinates added to the coordinates of this point. |
| public Point3D | |
| public double | Returns: the angle between the two vectors measured in degreesthe X magnitude of the other vector x, double the Y magnitude of the other vector y, double the Z magnitude of the other vector z)Computes the angle (in degrees) between the vector represented by this point and the specified vector. |
| public double | |
| public double | |
| public Point3D | Returns: the cross product of the two vectorsthe X magnitude of the other vector x, double the Y magnitude of the other vector y, double the Z magnitude of the other vector z)Computes cross product of the vector represented by this instance and the specified vector. |
| public Point3D | Returns: the cross product of the two vectorsthe other vector vector)Computes cross product of the vector represented by this instance and the specified vector. |
| public double | Returns: the distance between this point and point(x1, y1, z1).the x coordinate of other point x1, double the y coordinate of other point y1, double the z coordinate of other point z1)Computes the distance between this point and point |
| public double | |
| public double | Returns: the dot product of the two vectorsthe X magnitude of the other vector x, double the Y magnitude of the other vector y, double the Z magnitude of the other vector z)Computes dot (scalar) product of the vector represented by this instance and the specified vector. |
| public double | Returns: the dot product of the two vectorsthe other vector vector)Computes dot (scalar) product of the vector represented by this instance and the specified vector. |
| public boolean | Returns: true if this Point3D is the same as the obj argument; false otherwisethe reference object with which to compare obj)Overrides java. Indicates whether some other object is "equal to" this one. |
| public final double | |
| public final double | |
| public final double | |
| public int | Returns: a hash code for thisPoint3D object.Overrides java. Returns a hash code for this |
| public Point3D | interpolate(Point3D endValue, double t)
Implements javafx. Returns an intermediate value between the value of this |
| public double | Returns: magnitude of the vectorComputes magnitude (length) of the relative magnitude vector represented by this instance. |
| public Point3D | Returns: the point in the middlethe X coordinate of the second endpoint x, double the Y coordinate of the second endpoint y, double the Z coordinate of the second endpoint z)Returns a point which lies in the middle between this point and the specified coordinates. |
| public Point3D | |
| public Point3D | Returns: the point with multiplied coordinatesthe factor multiplying the coordinates factor)Returns a point with the coordinates of this point multiplied by the specified factor |
| public Point3D | Returns: the normalized vector represented by aPoint3D instanceNormalizes the relative magnitude vector represented by this instance. |
| public Point3D | Returns: the point with subtracted coordinatesthe X coordinate subtraction x, double the Y coordinate subtraction y, double the Z coordinate subtraction z)Returns a point with the specified coordinates subtracted from the coordinates of this point. |
| public Point3D | |
| public String |
| hash | back to summary |
|---|---|
| private int hash Cache the hash code to make computing hashes faster. | |
| x | back to summary |
|---|---|
| private final double x The x coordinate.
| |
| y | back to summary |
|---|---|
| private final double y The y coordinate.
| |
| z | back to summary |
|---|---|
| private final double z The z coordinate.
| |
| ZERO | back to summary |
|---|---|
| public static final Point3D ZERO Point or vector with all three coordinates set to 0. | |
| Point3D | back to summary |
|---|---|
| public Point3D(double x, double y, double z) Creates a new instance of
| |
| add | back to summary |
|---|---|
| public Point3D add(double x, double y, double z) Returns a point with the specified coordinates added to the coordinates of this point.
| |
| add | back to summary |
|---|---|
| public Point3D add(Point3D point) Returns a point with the coordinates of the specified point added to the coordinates of this point.
| |
| angle | back to summary |
|---|---|
| public double angle(double x, double y, double z) Computes the angle (in degrees) between the vector represented by this point and the specified vector.
| |
| angle | back to summary |
|---|---|
| public double angle(Point3D point) Computes the angle (in degrees) between the vector represented by this point and the vector represented by the specified point.
| |
| angle | back to summary |
|---|---|
| public double angle(Point3D p1, Point3D p2) Computes the angle (in degrees) between the three points with this point as a vertex.
| |
| crossProduct | back to summary |
|---|---|
| public Point3D crossProduct(double x, double y, double z) Computes cross product of the vector represented by this instance and the specified vector.
| |
| crossProduct | back to summary |
|---|---|
| public Point3D crossProduct(Point3D vector) Computes cross product of the vector represented by this instance and the specified vector.
| |
| distance | back to summary |
|---|---|
| public double distance(double x1, double y1, double z1) Computes the distance between this point and point
| |
| distance | back to summary |
|---|---|
| public double distance(Point3D point) Computes the distance between this point and the specified
| |
| dotProduct | back to summary |
|---|---|
| public double dotProduct(double x, double y, double z) Computes dot (scalar) product of the vector represented by this instance and the specified vector.
| |
| dotProduct | back to summary |
|---|---|
| public double dotProduct(Point3D vector) Computes dot (scalar) product of the vector represented by this instance and the specified vector.
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Overrides java. Indicates whether some other object is "equal to" this one.
Two instances of | |
| getX | back to summary |
|---|---|
| public final double getX() The x coordinate.
| |
| getY | back to summary |
|---|---|
| public final double getY() The y coordinate.
| |
| getZ | back to summary |
|---|---|
| public final double getZ() The z coordinate.
| |
| hashCode | back to summary |
|---|---|
| public int hashCode() Overrides java. Returns a hash code for this
| |
| interpolate | back to summary |
|---|---|
| public Point3D interpolate(Point3D endValue, double t) Implements javafx. Doc from javafx. Returns an intermediate value between the value of this The returned value might not be a new instance; the implementation might also return one of the two existing instances if the intermediate value would be equal to one of the existing values. However, this is an optimization and applications should not assume any particular identity of the returned value.
| |
| magnitude | back to summary |
|---|---|
| public double magnitude() Computes magnitude (length) of the relative magnitude vector represented by this instance.
| |
| midpoint | back to summary |
|---|---|
| public Point3D midpoint(double x, double y, double z) Returns a point which lies in the middle between this point and the specified coordinates.
| |
| midpoint | back to summary |
|---|---|
| public Point3D midpoint(Point3D point) Returns a point which lies in the middle between this point and the specified point.
| |
| multiply | back to summary |
|---|---|
| public Point3D multiply(double factor) Returns a point with the coordinates of this point multiplied by the specified factor
| |
| normalize | back to summary |
|---|---|
| public Point3D normalize() Normalizes the relative magnitude vector represented by this instance. Returns a vector with the same direction and magnitude equal to 1. If this is a zero vector, a zero vector is returned.
| |
| subtract | back to summary |
|---|---|
| public Point3D subtract(double x, double y, double z) Returns a point with the specified coordinates subtracted from the coordinates of this point.
| |
| subtract | back to summary |
|---|---|
| public Point3D subtract(Point3D point) Returns a point with the coordinates of the specified point subtracted from the coordinates of this point.
| |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. Returns a string representation of this
| |