MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/PhysX / lookAt

Method lookAt

physx/samples/samplebase/SampleCamera.cpp:100–109  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

98}
99
100void Camera::lookAt(const PxVec3& position, const PxVec3& target)
101{
102 PxVec3 dir, right, up;
103 Ps::computeBasis(position, target, dir, right, up);
104
105 PxTransform view;
106 view.p = position;
107 view.q = PxQuat(PxMat33(-right, up, -dir));
108 setView(view);
109}
110
111
112 enum FrustumPlaneIndex

Callers 1

onTickPreRenderMethod · 0.80

Calls 3

computeBasisFunction · 0.85
PxQuatClass · 0.50
PxMat33Class · 0.50

Tested by

no test coverage detected