Uses of Interface
org.joml.Vector3dc
Packages that use Vector3dc
-
Uses of Vector3dc in org.joml
Modifier and TypeClassDescriptionclass
Contains the definition of a Vector comprising 3 doubles and associated transformations.Modifier and TypeMethodDescriptionVector3d.getToAddress
(long address) Vector3dc.getToAddress
(long address) Store this vector at the given off-heap memory address.Modifier and TypeMethodDescriptionAdd the supplied vector to this one.Add the supplied vector to this one and store the result indest
.double
double
Return the angle between this vector and the supplied vector.double
double
Return the cosine of the angle betweenthis
vector and the supplied vector.double
Vector3d.angleSigned
(Vector3dc v, Vector3dc n) double
Vector3dc.angleSigned
(Vector3dc v, Vector3dc n) Return the signed angle between this vector and the supplied vector with respect to the plane with the given normal vectorn
.Apply an arcball view transformation to this matrix with the givenradius
andcenter
position of the arcball and the specified X and Y rotation angles.Apply an arcball view transformation to this matrix with the givenradius
andcenter
position of the arcball and the specified X and Y rotation angles, and store the result indest
.Apply an arcball view transformation to this matrix with the givenradius
andcenter
position of the arcball and the specified X and Y rotation angles.Matrix4x3d.arcball
(double radius, Vector3dc center, double angleX, double angleY, Matrix4x3d dest) Matrix4x3dc.arcball
(double radius, Vector3dc center, double angleX, double angleY, Matrix4x3d dest) Apply an arcball view transformation to this matrix with the givenradius
andcenter
position of the arcball and the specified X and Y rotation angles, and store the result indest
.Matrix4d.billboardCylindrical
(Vector3dc objPos, Vector3dc targetPos, Vector3dc up) Set this matrix to a cylindrical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
while constraining a cylindrical rotation around the givenup
vector.Matrix4x3d.billboardCylindrical
(Vector3dc objPos, Vector3dc targetPos, Vector3dc up) Set this matrix to a cylindrical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
while constraining a cylindrical rotation around the givenup
vector.Matrix4d.billboardSpherical
(Vector3dc objPos, Vector3dc targetPos) Set this matrix to a spherical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
using a shortest arc rotation by not preserving any up vector of the object.Matrix4d.billboardSpherical
(Vector3dc objPos, Vector3dc targetPos, Vector3dc up) Set this matrix to a spherical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
.Matrix4x3d.billboardSpherical
(Vector3dc objPos, Vector3dc targetPos) Set this matrix to a spherical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
using a shortest arc rotation by not preserving any up vector of the object.Matrix4x3d.billboardSpherical
(Vector3dc objPos, Vector3dc targetPos, Vector3dc up) Set this matrix to a spherical billboard transformation that rotates the local +Z axis of a given object with positionobjPos
towards a target position attargetPos
.Set this vector to be the cross product of this and v2.Calculate the cross product of this and v2 and store the result indest
.double
double
Return the distance between this vector andv
.double
Vector3d.distanceSquared
(Vector3dc v) double
Vector3dc.distanceSquared
(Vector3dc v) Return the square of the distance between this vector andv
.Divide this byv
component-wise and store the result intodest
.double
double
Return the dot product of this vector and the supplied vector.boolean
boolean
Compare the vector components ofthis
vector with the given vector using the givendelta
and return whether all of them are equal within a maximum difference ofdelta
.static int
Intersectiond.findClosestPointOnTriangle
(Vector3dc v0, Vector3dc v1, Vector3dc v2, Vector3dc p, Vector3d result) Determine the closest point on the triangle with the verticesv0
,v1
,v2
between that triangle and the given pointp
and store that point into the givenresult
.Add the component-wise multiplication ofa * b
to this vector.Add the component-wise multiplication ofa * b
to this vector.Add the component-wise multiplication ofa * b
to this vector and store the result indest
.Add the component-wise multiplication ofa * b
to this vector and store the result indest
.Add the component-wise multiplication ofa * b
to this vector and store the result indest
.Quaterniond.fromAxisAngleDeg
(Vector3dc axis, double angle) Set this quaternion to be a representation of the supplied axis and angle (in degrees).Quaterniond.fromAxisAngleRad
(Vector3dc axis, double angle) Set this quaternion to be a representation of the supplied axis and angle (in radians).Compute the half vector between this and the other vector.Compute the half vector between this and the other vector and store the result indest
.Compute a hermite interpolation betweenthis
vector and its associated tangentt0
and the given vectorv
with its tangentt1
and store the result indest
.static int
Intersectiond.intersectLineSegmentAab
(Vector3dc p0, Vector3dc p1, Vector3dc min, Vector3dc max, Vector2d result) Determine whether the undirected line segment with the end pointsp0
andp1
intersects the axis-aligned box given as its minimum cornermin
and maximum cornermax
, and return the values of the parameter t in the ray equation p(t) = origin + p0 * (p1 - p0) of the near and far point of intersection.static boolean
Intersectiond.intersectLineSegmentTriangle
(Vector3dc p0, Vector3dc p1, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon, Vector3d intersectionPoint) Determine whether the line segment with the end pointsp0
andp1
intersects the triangle consisting of the three vertices(v0X, v0Y, v0Z)
,(v1X, v1Y, v1Z)
and(v2X, v2Y, v2Z)
, regardless of the winding order of the triangle or the direction of the line segment between its two end points, and return the point of intersection.static boolean
Intersectiond.intersectRayAab
(Vector3dc origin, Vector3dc dir, Vector3dc min, Vector3dc max, Vector2d result) Test whether the ray with the givenorigin
and directiondir
intersects the axis-aligned box specified as its minimum cornermin
and maximum cornermax
, and return the values of the parameter t in the ray equation p(t) = origin + t * dir of the near and far point of intersection..static double
Intersectiond.intersectRayPlane
(Vector3dc origin, Vector3dc dir, Vector3dc point, Vector3dc normal, double epsilon) Test whether the ray with givenorigin
and directiondir
intersects the plane containing the givenpoint
and having the givennormal
, and return the value of the parameter t in the ray equation p(t) = origin + t * dir of the intersection point.static boolean
Intersectiond.intersectRaySphere
(Vector3dc origin, Vector3dc dir, Vector3dc center, double radiusSquared, Vector2d result) Test whether the ray with the givenorigin
and normalized directiondir
intersects the sphere with the givencenter
and square radiusradiusSquared
, and store the values of the parameter t in the ray equation p(t) = origin + t * dir for both points (near and far) of intersections into the givenresult
vector.static double
Intersectiond.intersectRayTriangle
(Vector3dc origin, Vector3dc dir, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon) Determine whether the ray with the givenorigin
and the givendir
intersects the triangle consisting of the three verticesv0
,v1
andv2
and return the value of the parameter t in the ray equation p(t) = origin + t * dir of the point of intersection.static double
Intersectiond.intersectRayTriangleFront
(Vector3dc origin, Vector3dc dir, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon) Determine whether the ray with the givenorigin
and the givendir
intersects the frontface of the triangle consisting of the three verticesv0
,v1
andv2
and return the value of the parameter t in the ray equation p(t) = origin + t * dir of the point of intersection.static boolean
Intersectiond.intersectSphereSphere
(Vector3dc centerA, double radiusSquaredA, Vector3dc centerB, double radiusSquaredB, Vector4d centerAndRadiusOfIntersectionCircle) Test whether the one sphere with centercenterA
and square radiusradiusSquaredA
intersects the other sphere with centercenterB
and square radiusradiusSquaredB
, and store the center of the circle of intersection in the(x, y, z)
components of the supplied vector and the radius of that circle in the w component.Linearly interpolatethis
andother
using the given interpolation factort
and store the result inthis
.Linearly interpolatethis
andother
using the given interpolation factort
and store the result indest
.Apply a rotation transformation to this matrix to make-z
point alongdir
.Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Apply a rotation transformation to this matrix to make-z
point alongdir
.Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Apply a rotation transformation to this matrix to make-z
point alongdir
.Matrix4x3d.lookAlong
(Vector3dc dir, Vector3dc up, Matrix4x3d dest) Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Matrix4x3dc.lookAlong
(Vector3dc dir, Vector3dc up, Matrix4x3d dest) Apply a rotation transformation to this matrix to make-z
point alongdir
and store the result indest
.Apply a rotation to this quaternion that maps the given direction to the positive Z axis.Quaterniond.lookAlong
(Vector3dc dir, Vector3dc up, Quaterniond dest) Quaterniondc.lookAlong
(Vector3dc dir, Vector3dc up, Quaterniond dest) Apply a rotation to this quaternion that maps the given direction to the positive Z axis, and store the result indest
.Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
.Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
and store the result indest
.Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
and store the result indest
.Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
.Matrix4x3d.lookAt
(Vector3dc eye, Vector3dc center, Vector3dc up, Matrix4x3d dest) Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
and store the result indest
.Matrix4x3dc.lookAt
(Vector3dc eye, Vector3dc center, Vector3dc up, Matrix4x3d dest) Apply a "lookat" transformation to this matrix for a right-handed coordinate system, that aligns-z
withcenter - eye
and store the result indest
.Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
.Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
and store the result indest
.Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
and store the result indest
.Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
.Matrix4x3d.lookAtLH
(Vector3dc eye, Vector3dc center, Vector3dc up, Matrix4x3d dest) Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
and store the result indest
.Matrix4x3dc.lookAtLH
(Vector3dc eye, Vector3dc center, Vector3dc up, Matrix4x3d dest) Apply a "lookat" transformation to this matrix for a left-handed coordinate system, that aligns+z
withcenter - eye
and store the result indest
.Set the components of this vector to be the component-wise maximum of this and the other vector.Set the components ofdest
to be the component-wise maximum of this and the other vector.Set the components of this vector to be the component-wise minimum of this and the other vector.Set the components ofdest
to be the component-wise minimum of this and the other vector.Multiply this Vector3d component-wise by another Vector3dc.Multiply this byv
component-wise and store the result intodest
.Add the component-wise multiplication ofthis * a
tob
and store the result inthis
.Add the component-wise multiplication ofthis * a
tob
and store the result inthis
.Add the component-wise multiplication ofthis * a
tob
and store the result indest
.Add the component-wise multiplication ofthis * a
tob
and store the result indest
.Add the component-wise multiplication ofthis * a
tob
and store the result indest
.Vector3d.orthogonalize
(Vector3dc v) Transformthis
vector so that it is orthogonal to the given vectorv
and normalize the result.Vector3d.orthogonalize
(Vector3dc v, Vector3d dest) Vector3dc.orthogonalize
(Vector3dc v, Vector3d dest) Transformthis
vector so that it is orthogonal to the given vectorv
, normalize the result and store it intodest
.Vector3d.orthogonalizeUnit
(Vector3dc v) Transformthis
vector so that it is orthogonal to the given unit vectorv
and normalize the result.Vector3d.orthogonalizeUnit
(Vector3dc v, Vector3d dest) Vector3dc.orthogonalizeUnit
(Vector3dc v, Vector3d dest) Transformthis
vector so that it is orthogonal to the given unit vectorv
, normalize the result and store it intodest
.Project the givenposition
viathis
matrix using the specified viewport and store the resulting window coordinates inwinCoordsDest
.Project the givenposition
viathis
matrix using the specified viewport and store the resulting window coordinates inwinCoordsDest
.double
Matrix3d.quadraticFormProduct
(Vector3dc v) double
Matrix3dc.quadraticFormProduct
(Vector3dc v) Computev^T * this * v
.Apply a mirror/reflection transformation to this matrix that reflects through the given plane specified via the plane normal.Apply a mirror/reflection transformation to this matrix that reflects through the given plane specified via the plane normal, and store the result indest
.Matrix4d.reflect
(Quaterniondc orientation, Vector3dc point) Apply a mirror/reflection transformation to this matrix that reflects about a plane specified via the plane orientation and a point on the plane.Matrix4d.reflect
(Quaterniondc orientation, Vector3dc point, Matrix4d dest) Apply a mirror/reflection transformation to this matrix that reflects about the given plane specified via the plane normal and a point on the plane.Matrix4dc.reflect
(Quaterniondc orientation, Vector3dc point, Matrix4d dest) Apply a mirror/reflection transformation to this matrix that reflects about a plane specified via the plane orientation and a point on the plane, and store the result indest
.Apply a mirror/reflection transformation to this matrix that reflects about the given plane specified via the plane normal and a point on the plane, and store the result indest
.Matrix4x3d.reflect
(Quaterniondc orientation, Vector3dc point) Apply a mirror/reflection transformation to this matrix that reflects about a plane specified via the plane orientation and a point on the plane.Matrix4x3d.reflect
(Quaterniondc orientation, Vector3dc point, Matrix4x3d dest) Apply a mirror/reflection transformation to this matrix that reflects about the given plane specified via the plane normal and a point on the plane.Matrix4x3d.reflect
(Vector3dc normal, Vector3dc point, Matrix4x3d dest) Matrix4x3dc.reflect
(Quaterniondc orientation, Vector3dc point, Matrix4x3d dest) Apply a mirror/reflection transformation to this matrix that reflects about a plane specified via the plane orientation and a point on the plane, and store the result indest
.Matrix4x3dc.reflect
(Vector3dc normal, Vector3dc point, Matrix4x3d dest) Apply a mirror/reflection transformation to this matrix that reflects about the given plane specified via the plane normal and a point on the plane, and store the result indest
.Reflect this vector about the given normal vector.Reflect this vector about the given normal vector and store the result indest
.Matrix3d.reflection
(Vector3dc normal) Set this matrix to a mirror/reflection transformation that reflects through the given plane specified via the plane normal.Matrix4d.reflection
(Quaterniondc orientation, Vector3dc point) Set this matrix to a mirror/reflection transformation that reflects about a plane specified via the plane orientation and a point on the plane.Matrix4d.reflection
(Vector3dc normal, Vector3dc point) Set this matrix to a mirror/reflection transformation that reflects about the given plane specified via the plane normal and a point on the plane.Matrix4x3d.reflection
(Quaterniondc orientation, Vector3dc point) Set this matrix to a mirror/reflection transformation that reflects about a plane specified via the plane orientation and a point on the plane.Matrix4x3d.reflection
(Vector3dc normal, Vector3dc point) Set this matrix to a mirror/reflection transformation that reflects about the given plane specified via the plane normal and a point on the plane.Apply a rotation transformation, rotating the given radians about the specified axis, to this matrix.Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Apply a rotation transformation, rotating the given radians about the specified axis, to this matrix.Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Apply a rotation transformation, rotating the given radians about the specified axis, to this matrix.Matrix4x3d.rotate
(double angle, Vector3dc axis, Matrix4x3d dest) Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Matrix4x3dc.rotate
(double angle, Vector3dc axis, Matrix4x3d dest) Apply a rotation transformation, rotating the given radians about the specified axis and store the result indest
.Quaterniond.rotateAxis
(double angle, Vector3dc axis) Apply a rotation tothis
quaternion rotating the given radians about the specified axis.Quaterniond.rotateAxis
(double angle, Vector3dc axis, Quaterniond dest) Quaterniondc.rotateAxis
(double angle, Vector3dc axis, Quaterniond dest) Apply a rotation tothis
quaternion rotating the given radians about the specified axis and store the result indest
.Apply a rotation tothis
that rotates thefromDir
vector to point alongtoDir
.Quaterniond.rotateTo
(Vector3dc fromDir, Vector3dc toDir, Quaterniond dest) Quaterniondc.rotateTo
(Vector3dc fromDir, Vector3dc toDir, Quaterniond dest) Apply a rotation tothis
that rotates thefromDir
vector to point alongtoDir
and store the result indest
.Matrix3d.rotateTowards
(Vector3dc direction, Vector3dc up) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
.Matrix3d.rotateTowards
(Vector3dc direction, Vector3dc up, Matrix3d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
and store the result indest
.Matrix3dc.rotateTowards
(Vector3dc direction, Vector3dc up, Matrix3d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
and store the result indest
.Matrix4d.rotateTowards
(Vector3dc direction, Vector3dc up) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
.Matrix4d.rotateTowards
(Vector3dc direction, Vector3dc up, Matrix4d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
and store the result indest
.Matrix4dc.rotateTowards
(Vector3dc direction, Vector3dc up, Matrix4d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdirection
and store the result indest
.Matrix4x3d.rotateTowards
(Vector3dc dir, Vector3dc up) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdir
.Matrix4x3d.rotateTowards
(Vector3dc dir, Vector3dc up, Matrix4x3d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the local+Z
axis withdir
and store the result indest
.Matrix4x3dc.rotateTowards
(Vector3dc dir, Vector3dc up, Matrix4x3d dest) Apply a model transformation to this matrix for a right-handed coordinate system, that aligns the-z
axis withdir
and store the result indest
.Set this matrix to a rotation matrix which rotates the given radians about a given axis.Set this matrix to a rotation matrix which rotates the given radians about a given axis.Set this matrix to a rotation matrix which rotates the given radians about a given axis.Quaterniond.rotationTo
(Vector3dc fromDir, Vector3dc toDir) Setthis
quaternion to a rotation that rotates thefromDir
vector to point alongtoDir
.Vector3d.rotationTo
(Vector3dc toDir, Quaterniond dest) Vector3dc.rotationTo
(Vector3dc toDir, Quaterniond dest) Compute the quaternion representing a rotation ofthis
vector to point alongtoDir
and store the result indest
.Matrix3d.rotationTowards
(Vector3dc dir, Vector3dc up) Set this matrix to a model transformation for a right-handed coordinate system, that aligns the local-z
axis withcenter - eye
.Matrix4d.rotationTowards
(Vector3dc dir, Vector3dc up) Set this matrix to a model transformation for a right-handed coordinate system, that aligns the local-z
axis withdir
.Matrix4x3d.rotationTowards
(Vector3dc dir, Vector3dc up) Set this matrix to a model transformation for a right-handed coordinate system, that aligns the local-z
axis withdir
.Apply scaling to this matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively.Apply scaling tothis
matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively and store the result indest
.Apply scaling to this matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively.Apply scaling tothis
matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively and store the result indest
.Apply scaling to this matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively.Matrix4x3d.scale
(Vector3dc xyz, Matrix4x3d dest) Matrix4x3dc.scale
(Vector3dc xyz, Matrix4x3d dest) Apply scaling tothis
matrix by scaling the base axes by the givenxyz.x
,xyz.y
andxyz.z
factors, respectively and store the result indest
.Set this matrix to be a simple scale matrix which scales the base axes byxyz.x
,xyz.y
andxyz.z
respectively.Set this matrix to be a simple scale matrix which scales the base axes byxyz.x
,xyz.y
andxyz.z
, respectively.Set this matrix to be a simple scale matrix which scales the base axes byxyz.x
,xyz.y
andxyz.z
, respectively.Set thisAxisAngle4d
to the given values.Set the three columns of this matrix to the supplied vectors, respectively.Set the four columns of this matrix to the supplied vectors, respectively.Set the x, y and z components to match the supplied vector.Set the x, y and z components to match the supplied vector.Set thisVector3i
to the values of v usingRoundingMode.TRUNCATE
rounding.Set thisVector3i
to the values of v using the givenRoundingMode
.Set the x, y, and z components of this to the components ofv
and the w component tow
.Quaterniond.setAngleAxis
(double angle, Vector3dc axis) Set this quaternion to be a representation of the supplied axis and angle (in radians).Set the column at the givencolumn
index, starting with0
.Set the column at the givencolumn
index, starting with0
.Matrix3d.setLookAlong
(Vector3dc dir, Vector3dc up) Set this matrix to a rotation transformation to make-z
point alongdir
.Matrix4d.setLookAlong
(Vector3dc dir, Vector3dc up) Set this matrix to a rotation transformation to make-z
point alongdir
.Matrix4x3d.setLookAlong
(Vector3dc dir, Vector3dc up) Set this matrix to a rotation transformation to make-z
point alongdir
.Set this matrix to be a "lookat" transformation for a right-handed coordinate system, that aligns-z
withcenter - eye
.Set this matrix to be a "lookat" transformation for a right-handed coordinate system, that aligns-z
withcenter - eye
.Matrix4d.setLookAtLH
(Vector3dc eye, Vector3dc center, Vector3dc up) Set this matrix to be a "lookat" transformation for a left-handed coordinate system, that aligns+z
withcenter - eye
.Matrix4x3d.setLookAtLH
(Vector3dc eye, Vector3dc center, Vector3dc up) Set this matrix to be a "lookat" transformation for a left-handed coordinate system, that aligns+z
withcenter - eye
.Set the row at the givenrow
index, starting with0
.Matrix4d.setTranslation
(Vector3dc xyz) Set only the translation components(m30, m31, m32)
of this matrix to the given values(xyz.x, xyz.y, xyz.z)
.Matrix4x3d.setTranslation
(Vector3dc xyz) Set only the translation components(m30, m31, m32)
of this matrix to the given values(xyz.x, xyz.y, xyz.z)
.Vector3d.smoothStep
(Vector3dc v, double t, Vector3d dest) Vector3dc.smoothStep
(Vector3dc v, double t, Vector3d dest) Compute a smooth-step (i.e.Subtract the supplied vector from this one.Subtract the supplied vector from this one and store the result indest
.static boolean
Intersectiond.testAabAab
(Vector3dc minA, Vector3dc maxA, Vector3dc minB, Vector3dc maxB) Test whether the axis-aligned box with minimum cornerminA
and maximum cornermaxA
intersects the axis-aligned box with minimum cornerminB
and maximum cornermaxB
.static boolean
Intersectiond.testAabPlane
(Vector3dc min, Vector3dc max, double a, double b, double c, double d) Test whether the axis-aligned box with minimum cornermin
and maximum cornermax
intersects the plane with the general equation a*x + b*y + c*z + d = 0.static boolean
Intersectiond.testAabSphere
(Vector3dc min, Vector3dc max, Vector3dc center, double radiusSquared) Test whether the axis-aligned box with minimum cornermin
and maximum cornermax
intersects the sphere with the givencenter
and square radiusradiusSquared
.static boolean
Intersectiond.testLineSegmentSphere
(Vector3dc p0, Vector3dc p1, Vector3dc center, double radiusSquared) Test whether the line segment with the end pointsp0
andp1
intersects the given sphere with centercenter
and square radiusradiusSquared
.static boolean
Intersectiond.testLineSegmentTriangle
(Vector3dc p0, Vector3dc p1, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon) Test whether the line segment with the end pointsp0
andp1
intersects the triangle consisting of the three vertices(v0X, v0Y, v0Z)
,(v1X, v1Y, v1Z)
and(v2X, v2Y, v2Z)
, regardless of the winding order of the triangle or the direction of the line segment between its two end points.static boolean
Intersectiond.testRayAab
(Vector3dc origin, Vector3dc dir, Vector3dc min, Vector3dc max) Test whether the ray with the givenorigin
and directiondir
intersects the axis-aligned box specified as its minimum cornermin
and maximum cornermax
.static boolean
Intersectiond.testRaySphere
(Vector3dc origin, Vector3dc dir, Vector3dc center, double radiusSquared) Test whether the ray with the givenorigin
and normalized directiondir
intersects the sphere with the givencenter
and square radius.static boolean
Intersectiond.testRayTriangle
(Vector3dc origin, Vector3dc dir, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon) Test whether the ray with the givenorigin
and the givendir
intersects the frontface of the triangle consisting of the three verticesv0
,v1
andv2
.static boolean
Intersectiond.testRayTriangleFront
(Vector3dc origin, Vector3dc dir, Vector3dc v0, Vector3dc v1, Vector3dc v2, double epsilon) Test whether the ray with the givenorigin
and the givendir
intersects the frontface of the triangle consisting of the three verticesv0
,v1
andv2
.static boolean
Intersectiond.testSphereSphere
(Vector3dc centerA, double radiusSquaredA, Vector3dc centerB, double radiusSquaredB) Test whether the one sphere with centercenterA
and square radiusradiusSquaredA
intersects the other sphere with centercenterB
and square radiusradiusSquaredB
.Transform the given vector by the rotation transformation described by thisAxisAngle4d
and store the result indest
.Transform the given vector by this matrix and store the result indest
.Transform/multiply the given vector by this matrix by assuming a third row in this matrix of(0, 0, 1)
and store the result indest
.Transform/multiply the given vector by this matrix and store the result indest
.Transform the given vector by this quaternion and store the result indest
.Transform the given vector by this quaternion and store the result indest
.Matrix4d.transformAab
(Vector3dc min, Vector3dc max, Vector3d outMin, Vector3d outMax) Matrix4dc.transformAab
(Vector3dc min, Vector3dc max, Vector3d outMin, Vector3d outMax) Transform the axis-aligned box given as the minimum cornermin
and maximum cornermax
bythis
affine
matrix and compute the axis-aligned box of the result whose minimum corner is stored inoutMin
and maximum corner stored inoutMax
.Matrix4x3d.transformAab
(Vector3dc min, Vector3dc max, Vector3d outMin, Vector3d outMax) Matrix4x3dc.transformAab
(Vector3dc min, Vector3dc max, Vector3d outMin, Vector3d outMax) Transform the axis-aligned box given as the minimum cornermin
and maximum cornermax
bythis
matrix and compute the axis-aligned box of the result whose minimum corner is stored inoutMin
and maximum corner stored inoutMax
.Matrix4d.transformDirection
(Vector3dc v, Vector3d dest) Matrix4dc.transformDirection
(Vector3dc v, Vector3d dest) Transform/multiply the given 3D-vector, as if it was a 4D-vector with w=0, by this matrix and store the result indest
.Matrix4x3d.transformDirection
(Vector3dc v, Vector3d dest) Matrix4x3dc.transformDirection
(Vector3dc v, Vector3d dest) Transform/multiply the given 3D-vector, as if it was a 4D-vector with w=0, by this matrix and store the result indest
.Quaterniond.transformInverse
(Vector3dc vec, Vector3d dest) Quaterniondc.transformInverse
(Vector3dc vec, Vector3d dest) Transform the given vector by the inverse of this quaternion and store the result indest
.Quaternionf.transformInverse
(Vector3dc vec, Vector3d dest) Quaternionfc.transformInverse
(Vector3dc vec, Vector3d dest) Transform the given vector by the inverse of this quaternion and store the result indest
.Quaterniond.transformInverseUnit
(Vector3dc vec, Vector3d dest) Quaterniondc.transformInverseUnit
(Vector3dc vec, Vector3d dest) Transform the given vector by the inverse of this unit quaternion and store the result indest
.Quaternionf.transformInverseUnit
(Vector3dc vec, Vector3d dest) Quaternionfc.transformInverseUnit
(Vector3dc vec, Vector3d dest) Transform the given vector by the inverse of this unit quaternion and store the result indest
.Matrix4d.transformPosition
(Vector3dc v, Vector3d dest) Matrix4dc.transformPosition
(Vector3dc v, Vector3d dest) Transform/multiply the given 3D-vector, as if it was a 4D-vector with w=1, by this matrix and store the result indest
.Matrix4x3d.transformPosition
(Vector3dc v, Vector3d dest) Matrix4x3dc.transformPosition
(Vector3dc v, Vector3d dest) Transform/multiply the given 3D-vector, as if it was a 4D-vector with w=1, by this matrix and store the result indest
.Matrix4d.transformProject
(Vector3dc v, Vector3d dest) Matrix4dc.transformProject
(Vector3dc v, Vector3d dest) Transform/multiply the given vector by this matrix, perform perspective divide and store the result indest
.Matrix3d.transformTranspose
(Vector3dc v, Vector3d dest) Matrix3dc.transformTranspose
(Vector3dc v, Vector3d dest) Transform the given vector by the transpose of this matrix and store the result indest
.Quaterniond.transformUnit
(Vector3dc vec, Vector3d dest) Quaterniondc.transformUnit
(Vector3dc vec, Vector3d dest) Transform the given vector by this unit quaternion and store the result indest
.Quaternionf.transformUnit
(Vector3dc vec, Vector3d dest) Quaternionfc.transformUnit
(Vector3dc vec, Vector3d dest) Transform the given vector by this unit quaternion and store the result indest
.Apply a translation to this matrix by translating by the given number of units in x, y and z.Apply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Apply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Apply a translation to this matrix by translating by the given number of units in x, y and z.Matrix4x3d.translate
(Vector3dc offset, Matrix4x3d dest) Apply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4x3dc.translate
(Vector3dc offset, Matrix4x3d dest) Apply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4d.translateLocal
(Vector3dc offset) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z.Matrix4d.translateLocal
(Vector3dc offset, Matrix4d dest) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4dc.translateLocal
(Vector3dc offset, Matrix4d dest) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4x3d.translateLocal
(Vector3dc offset) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z.Matrix4x3d.translateLocal
(Vector3dc offset, Matrix4x3d dest) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4x3dc.translateLocal
(Vector3dc offset, Matrix4x3d dest) Pre-multiply a translation to this matrix by translating by the given number of units in x, y and z and store the result indest
.Matrix4d.translation
(Vector3dc offset) Set this matrix to be a simple translation matrix.Matrix4x3d.translation
(Vector3dc offset) Set this matrix to be a simple translation matrix.Matrix4d.translationRotate
(Vector3dc translation, Quaterniondc quat) Setthis
matrix toT * R
, whereT
is the giventranslation
andR
is a rotation transformation specified by the given quaternion.Matrix4x3d.translationRotate
(Vector3dc translation, Quaterniondc quat) Setthis
matrix toT * R
, whereT
is the giventranslation
andR
is a rotation transformation specified by the given quaternion.Matrix4x3d.translationRotateInvert
(Vector3dc translation, Quaterniondc quat) Setthis
matrix to(T * R)-1
, whereT
is the giventranslation
andR
is a rotation transformation specified by the given quaternion.Matrix4d.translationRotateScale
(Vector3dc translation, Quaterniondc quat, double scale) Setthis
matrix toT * R * S
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion, andS
is a scaling transformation which scales all three axes byscale
.Matrix4d.translationRotateScale
(Vector3dc translation, Quaterniondc quat, Vector3dc scale) Setthis
matrix toT * R * S
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion, andS
is a scaling transformation which scales the axes byscale
.Matrix4x3d.translationRotateScale
(Vector3dc translation, Quaterniondc quat, Vector3dc scale) Setthis
matrix toT * R * S
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion, andS
is a scaling transformation which scales the axes byscale
.Matrix4d.translationRotateScaleInvert
(Vector3dc translation, Quaterniondc quat, double scale) Setthis
matrix to(T * R * S)-1
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion, andS
is a scaling transformation which scales all three axes byscale
.Matrix4d.translationRotateScaleInvert
(Vector3dc translation, Quaterniondc quat, Vector3dc scale) Setthis
matrix to(T * R * S)-1
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion, andS
is a scaling transformation which scales the axes byscale
.Matrix4x3d.translationRotateScaleMul
(Vector3dc translation, Quaterniondc quat, Vector3dc scale, Matrix4x3dc m) Setthis
matrix toT * R * S * M
, whereT
is the giventranslation
,R
is a rotation transformation specified by the given quaternion,S
is a scaling transformation which scales the axes byscale
.Matrix4d.translationRotateTowards
(Vector3dc pos, Vector3dc dir, Vector3dc up) Set this matrix to a model transformation for a right-handed coordinate system, that translates to the givenpos
and aligns the local-z
axis withdir
.Matrix4x3d.translationRotateTowards
(Vector3dc pos, Vector3dc dir, Vector3dc up) Set this matrix to a model transformation for a right-handed coordinate system, that translates to the givenpos
and aligns the local-z
axis withdir
.Unproject the given window coordinateswinCoords
bythis
matrix using the specified viewport.Unproject the given window coordinateswinCoords
bythis
matrix using the specified viewport.Matrix4d.unprojectInv
(Vector3dc winCoords, int[] viewport, Vector3d dest) Matrix4d.unprojectInv
(Vector3dc winCoords, int[] viewport, Vector4d dest) Matrix4dc.unprojectInv
(Vector3dc winCoords, int[] viewport, Vector3d dest) Unproject the given window coordinateswinCoords
bythis
matrix using the specified viewport.Matrix4dc.unprojectInv
(Vector3dc winCoords, int[] viewport, Vector4d dest) Unproject the given window coordinateswinCoords
bythis
matrix using the specified viewport.Matrix4d.withLookAtUp
(Vector3dc up) Apply a transformation to this matrix to ensure that the local Y axis (as obtained byMatrix4d.positiveY(Vector3d)
) will be coplanar to the plane spanned by the local Z axis (as obtained byMatrix4d.positiveZ(Vector3d)
) and the given vectorup
.Matrix4d.withLookAtUp
(Vector3dc up, Matrix4d dest) Matrix4dc.withLookAtUp
(Vector3dc up, Matrix4d dest) Apply a transformation to this matrix to ensure that the local Y axis (as obtained byMatrix4dc.positiveY(Vector3d)
) will be coplanar to the plane spanned by the local Z axis (as obtained byMatrix4dc.positiveZ(Vector3d)
) and the given vectorup
, and store the result indest
.ModifierConstructorDescriptionAxisAngle4d
(double angle, Vector3dc v) Create a newAxisAngle4d
with the given values.Create a newMatrix3d
and initialize its three columns using the supplied vectors.Create a newVector3d
whose values will be copied from the given vector.Create a newVector3i
and initialize its components to the rounded value of the given vector.