Package com.j3d.engine.math.plane
Record Class AxisPlane
java.lang.Object
java.lang.Record
com.j3d.engine.math.plane.AxisPlane
- Record Components:
origin- The point on the planev1- The first orthogonal vectorv2- The second orthogonal vector
A plane defined by an origin point and two orthogonal vectors (v1 and v2) that lie within the plane.
These vectors define the local coordinate system of the plane.
- Author:
- Lehlogonolo Poole
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanIndicates whether some other object is "equal to" this one.inthashCode()Returns a hash code value for this object.Normalises the vectorsorigin()Returns the value of theoriginrecord component.pair()Returns aSamePaircontaining two references to this plane.Converts this AxisPlane to aNormalPlane.toString()Returns a string representation of this record class.toWorld(CartesianPoint point) static AxisPlaneusingOrigin(Vector3 origin, AxisPlane original) v1()Returns the value of thev1record component.v2()Returns the value of thev2record component.static AxisPlaneReturns a plane representing the XY-plane.static AxisPlaneReturns a plane representing the XZ-plane.static AxisPlaneReturns a plane representing the ZY-plane.
-
Field Details
-
Constructor Details
-
Method Details
-
usingOrigin
-
toWorld
-
fromWorld
-
normalize
Normalises the vectors- Returns:
- A new plane with the normalised vectors
-
toNormalPlane
Converts this AxisPlane to aNormalPlane.- Returns:
- A new
NormalPlanewith the same origin and a normal derived from this AxisPlane.
-
pair
Returns aSamePaircontaining two references to this plane.- Returns:
- A
SamePairof this plane.
-
sameAxes
-
sameAxes
-
XZ
Returns a plane representing the XZ-plane.- Parameters:
origin- The origin of the plane.- Returns:
- The XZ-plane.
-
XY
Returns a plane representing the XY-plane.- Parameters:
origin- The origin of the plane.- Returns:
- The XY-plane.
-
ZY
Returns a plane representing the ZY-plane.- Parameters:
origin- The origin of the plane.- Returns:
- The ZY-plane.
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
hashCode
public int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
origin
Returns the value of theoriginrecord component.- Returns:
- the value of the
originrecord component
-
v1
Returns the value of thev1record component.- Returns:
- the value of the
v1record component
-
v2
Returns the value of thev2record component.- Returns:
- the value of the
v2record component
-