Add perf timer to code block

This commit is contained in:
luiscuenca 2019-10-23 12:32:16 -07:00
parent f6aa4a2dd4
commit 9849205ca0
No known key found for this signature in database
GPG key ID: 2387ECD129A6961D

View file

@ -908,6 +908,9 @@ void MyAvatar::simulate(float deltaTime, bool inView) {
// Head's look at blending needs updating
// before we perform rig animations and IK.
{
PerformanceTimer perfTimer("lookat");
CameraMode mode = qApp->getCamera().getMode();
if (_scriptControlsHeadLookAt || mode == CAMERA_MODE_FIRST_PERSON_LOOK_AT || mode == CAMERA_MODE_FIRST_PERSON ||
mode == CAMERA_MODE_LOOK_AT || mode == CAMERA_MODE_SELFIE) {
@ -920,6 +923,7 @@ void MyAvatar::simulate(float deltaTime, bool inView) {
resetHeadLookAt();
_headLookAtActive = false;
}
}
// update sensorToWorldMatrix for camera and hand controllers
// before we perform rig animations and IK.