fix updating hole geometry

This commit is contained in:
casperlamboo 2017-11-22 12:45:51 +01:00
parent 602a334514
commit 5e27d0429d
1 changed files with 2 additions and 2 deletions

4
src/d3/ShapeMesh.js vendored
View File

@ -74,12 +74,12 @@ class ShapeMesh extends THREE.Object3D {
}
updateHoleGeometry(holes) {
if (!this._solid || !this._fill) return false;
if (holes === this._holes && !this._changedGeometry) return false;
if (!this._solid) return false;
this._holeMesh.geometry.dispose();
if (holes === null) {
if (holes === null || !this._fill) {
this._holeMesh.geometry = new THREE.Geometry().fromBufferGeometry(this._mesh.geometry);
return true;
}