Browse Source

Add check for bounding sphere

Temdog007 6 years ago
parent
commit
c5f771fbb4
1 changed files with 5 additions and 0 deletions
  1. 5 0
      editor/js/Sidebar.Geometry.js

+ 5 - 0
editor/js/Sidebar.Geometry.js

@@ -179,6 +179,11 @@ Sidebar.Geometry = function ( editor ) {
 
 
 			}
 			}
 
 
+			if ( geometry.boundingSphere === null ) {
+
+				geometry.computeBoundingSphere();
+
+			}
 			geometryBoundingSphere.setValue( Math.floor( geometry.boundingSphere.radius * 1000 ) / 1000 );
 			geometryBoundingSphere.setValue( Math.floor( geometry.boundingSphere.radius * 1000 ) / 1000 );
 
 
 		} else {
 		} else {