接口 ITransformationExtension
- 所有已知实现类:
Transformation
public interface ITransformationExtension
Extension interface for
Transformation
.-
方法概要
修饰符和类型方法说明default Transformation
applyOrigin
(org.joml.Vector3f origin) Returns a new transformation with a changed origin by applying the given parameter (which is relative to the current origin).default Transformation
Converts and returns a new transformation based on this transformation from assuming a center-block system to an opposing-corner-block system.default Transformation
Converts and returns a new transformation based on this transformation from assuming an opposing-corner-block system to a center-block system.default boolean
返回 whether this transformation is the identity transformation。default Direction
rotateTransform
(Direction facing) Rotates the direction according to this transformation and returns the nearestDirection
to the resulting direction.private Transformation
self()
default void
transformNormal
(org.joml.Vector3f normal) Transforms the normal according to this transformation and normalizes it.default void
transformPosition
(org.joml.Vector4f position) Transforms the position according to this transformation.
-
方法详细资料
-
self
-
isIdentity
default boolean isIdentity()返回 whether this transformation is the identity transformation。- 返回:
- whether this transformation is the identity transformation
- 另请参阅:
-
transformPosition
default void transformPosition(org.joml.Vector4f position) Transforms the position according to this transformation.- 参数:
position
- the position to transform
-
transformNormal
default void transformNormal(org.joml.Vector3f normal) Transforms the normal according to this transformation and normalizes it.- 参数:
normal
- the normal to transform
-
rotateTransform
Rotates the direction according to this transformation and returns the nearestDirection
to the resulting direction.- 参数:
facing
- the direction to transform- 返回:
- the
Direction
value nearest to the resulting transformed direction - 另请参阅:
-
blockCenterToCorner
Converts and returns a new transformation based on this transformation from assuming a center-block system to an opposing-corner-block system.- 返回:
- a new transformation using the opposing-corner-block system
-
blockCornerToCenter
Converts and returns a new transformation based on this transformation from assuming an opposing-corner-block system to a center-block system.- 返回:
- a new transformation using the center-block system
-
applyOrigin
Returns a new transformation with a changed origin by applying the given parameter (which is relative to the current origin). This can be used for switching between coordinate systems.- 参数:
origin
- the new origin as relative to the current origin- 返回:
- a new transformation with a changed origin
-