PT: TODO: copied from SampleApplication. Refactor.
| 60 | |
| 61 | // PT: TODO: copied from SampleApplication. Refactor. |
| 62 | static PxMat33 EulerToMat33(const PxVec3 &e) |
| 63 | { |
| 64 | float c1 = cosf(e.z); |
| 65 | float s1 = sinf(e.z); |
| 66 | float c2 = cosf(e.y); |
| 67 | float s2 = sinf(e.y); |
| 68 | float c3 = cosf(e.x); |
| 69 | float s3 = sinf(e.x); |
| 70 | PxMat33 m(PxVec3(c1*c2, -s1*c2, s2), |
| 71 | PxVec3((s1*c3)+(c1*s2*s3), (c1*c3)-(s1*s2*s3),-c2*s3), |
| 72 | PxVec3((s1*s3)-(c1*s2*c3), (c1*s3)+(s1*s2*c3), c2*c3)); |
| 73 | |
| 74 | return m; |
| 75 | } |
| 76 | |
| 77 | void Camera::updateInternals() |
| 78 | { |