Matrix4x4.CreateLookAt(Vector3, Vector3, Vector3) 方法

定义

创建视图矩阵。

public:
 static System::Numerics::Matrix4x4 CreateLookAt(System::Numerics::Vector3 cameraPosition, System::Numerics::Vector3 cameraTarget, System::Numerics::Vector3 cameraUpVector);
public static System.Numerics.Matrix4x4 CreateLookAt (System.Numerics.Vector3 cameraPosition, System.Numerics.Vector3 cameraTarget, System.Numerics.Vector3 cameraUpVector);
static member CreateLookAt : System.Numerics.Vector3 * System.Numerics.Vector3 * System.Numerics.Vector3 -> System.Numerics.Matrix4x4
Public Shared Function CreateLookAt (cameraPosition As Vector3, cameraTarget As Vector3, cameraUpVector As Vector3) As Matrix4x4

参数

cameraPosition
Vector3

照相机的位置。

cameraTarget
Vector3

照相机指向的目标。

cameraUpVector
Vector3

相对于照相机视角为“向上”的方向。

返回

视图矩阵。

适用于