Skip to content

KBE3D / KBCore / Cesium / Transforms / computeTemeToPseudoFixedMatrix

函数: computeTemeToPseudoFixedMatrix()

computeTemeToPseudoFixedMatrix(date: JulianDate, result?: Matrix3): Matrix3

Computes a rotation matrix to transform a point or vector from True Equator Mean Equinox (TEME) axes to the pseudo-fixed axes at a given time. This method treats the UT1 time standard as equivalent to UTC.

参数

date

JulianDate

The time at which to compute the rotation matrix.

result?

Matrix3

The object onto which to store the result.

返回

Matrix3

The modified result parameter or a new Matrix3 instance if none was provided.

示例

ts
//Set the view to the inertial frame.
scene.postUpdate.addEventListener(function(scene, time) {
   const now = Cesium.JulianDate.now();
   const offset = Cesium.Matrix4.multiplyByPoint(camera.transform, camera.position, new Cesium.Cartesian3());
   const transform = Cesium.Matrix4.fromRotationTranslation(Cesium.Transforms.computeTemeToPseudoFixedMatrix(now));
   const inverseTransform = Cesium.Matrix4.inverseTransformation(transform, new Cesium.Matrix4());
   Cesium.Matrix4.multiplyByPoint(inverseTransform, offset, offset);
   camera.lookAtTransform(transform, offset);
});

KBE3D @3.0.0 Copyright © 2024-present KBE3D