|
@@ -28,10 +28,12 @@ Sphere.prototype = {
|
|
|
|
|
|
setFromPoints: function () {
|
|
setFromPoints: function () {
|
|
|
|
|
|
- var box = new Box3();
|
|
|
|
|
|
+ var box;
|
|
|
|
|
|
return function setFromPoints( points, optionalCenter ) {
|
|
return function setFromPoints( points, optionalCenter ) {
|
|
|
|
|
|
|
|
+ box = box || new Box3();
|
|
|
|
+
|
|
var center = this.center;
|
|
var center = this.center;
|
|
|
|
|
|
if ( optionalCenter !== undefined ) {
|
|
if ( optionalCenter !== undefined ) {
|