mirror of
https://thingvellir.net/git/overte
synced 2025-03-27 23:52:03 +01:00
Merge pull request #7622 from hyperlogic/tony/frozen-avatar-fix
Fix for frozen ghost avatars
This commit is contained in:
commit
94f970dd89
1 changed files with 3 additions and 2 deletions
|
@ -187,9 +187,10 @@ void Avatar::simulate(float deltaTime) {
|
|||
|
||||
// simple frustum check
|
||||
float boundingRadius = getBoundingRadius();
|
||||
bool inView = qApp->getDisplayViewFrustum()->sphereIntersectsFrustum(getPosition(), boundingRadius);
|
||||
bool avatarPositionInView = qApp->getDisplayViewFrustum()->sphereIntersectsFrustum(getPosition(), boundingRadius);
|
||||
bool avatarMeshInView = qApp->getDisplayViewFrustum()->boxIntersectsFrustum(_skeletonModel->getRenderableMeshBound());
|
||||
|
||||
if (_shouldAnimate && !_shouldSkipRender && inView) {
|
||||
if (_shouldAnimate && !_shouldSkipRender && (avatarPositionInView || avatarMeshInView)) {
|
||||
{
|
||||
PerformanceTimer perfTimer("skeleton");
|
||||
_skeletonModel->getRig()->copyJointsFromJointData(_jointData);
|
||||
|
|
Loading…
Reference in a new issue