prevent double matrix updates
This commit is contained in:
parent
2060819700
commit
42d3e60ac1
1 changed files with 4 additions and 2 deletions
|
|
@ -152,12 +152,14 @@ mesh.object = class MeshObject {
|
||||||
);
|
);
|
||||||
let helper = this._boundsBox = new THREE.Box3Helper(b3, 0x555555);
|
let helper = this._boundsBox = new THREE.Box3Helper(b3, 0x555555);
|
||||||
world.add(helper);
|
world.add(helper);
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
matrixChanged() {
|
matrixChanged() {
|
||||||
this.object.updateMatrix();
|
if (!this.updateBoundsBox()) {
|
||||||
this.updateBoundsBox();
|
this.object.updateMatrix();
|
||||||
|
}
|
||||||
space.update();
|
space.update();
|
||||||
publish.matrix({ id: this.id, matrix: this.object.matrix });
|
publish.matrix({ id: this.id, matrix: this.object.matrix });
|
||||||
return this;
|
return this;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue