|
@@ -14,6 +14,8 @@ function LOD() {
|
|
|
|
|
|
Object3D.call( this );
|
|
|
|
|
|
+ this._currentLevel = 0;
|
|
|
+
|
|
|
this.type = 'LOD';
|
|
|
|
|
|
Object.defineProperties( this, {
|
|
@@ -33,8 +35,6 @@ LOD.prototype = Object.assign( Object.create( Object3D.prototype ), {
|
|
|
|
|
|
isLOD: true,
|
|
|
|
|
|
- currentLevel: 0,
|
|
|
-
|
|
|
copy: function ( source ) {
|
|
|
|
|
|
Object3D.prototype.copy.call( this, source, false );
|
|
@@ -81,6 +81,12 @@ LOD.prototype = Object.assign( Object.create( Object3D.prototype ), {
|
|
|
|
|
|
},
|
|
|
|
|
|
+ getCurrentLevel: function () {
|
|
|
+
|
|
|
+ return this._currentLevel;
|
|
|
+
|
|
|
+ },
|
|
|
+
|
|
|
getObjectForDistance: function ( distance ) {
|
|
|
|
|
|
var levels = this.levels;
|
|
@@ -149,7 +155,7 @@ LOD.prototype = Object.assign( Object.create( Object3D.prototype ), {
|
|
|
|
|
|
}
|
|
|
|
|
|
- this.currentLevel = i - 1;
|
|
|
+ this._currentLevel = i - 1;
|
|
|
|
|
|
for ( ; i < l; i ++ ) {
|
|
|
|