mirror of
https://github.com/Armored-Dragon/overte.git
synced 2025-03-11 16:13:16 +01:00
Add perf timer to code block
This commit is contained in:
parent
f6aa4a2dd4
commit
9849205ca0
1 changed files with 13 additions and 9 deletions
|
@ -908,17 +908,21 @@ void MyAvatar::simulate(float deltaTime, bool inView) {
|
|||
|
||||
// Head's look at blending needs updating
|
||||
// before we perform rig animations and IK.
|
||||
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) {
|
||||
if (!_pointAtActive || !_isPointTargetValid) {
|
||||
updateHeadLookAt(deltaTime);
|
||||
} else {
|
||||
{
|
||||
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) {
|
||||
if (!_pointAtActive || !_isPointTargetValid) {
|
||||
updateHeadLookAt(deltaTime);
|
||||
} else {
|
||||
resetHeadLookAt();
|
||||
}
|
||||
} else if (_headLookAtActive) {
|
||||
resetHeadLookAt();
|
||||
_headLookAtActive = false;
|
||||
}
|
||||
} else if (_headLookAtActive) {
|
||||
resetHeadLookAt();
|
||||
_headLookAtActive = false;
|
||||
}
|
||||
|
||||
// update sensorToWorldMatrix for camera and hand controllers
|
||||
|
|
Loading…
Reference in a new issue