setStateFromJSON method

dynamic setStateFromJSON(
  1. dynamic json
)

Implementation

setStateFromJSON(json) {
  // var state = JSON.parse( json );

  // if ( state.arcballState != null ) {

  // 	this._cameraMatrixState.fromArray( state.arcballState.cameraMatrix.elements );
  // 	this._cameraMatrixState.decompose( this.camera.position, this.camera.quaternion, this.camera.scale );

  // 	this.camera.up.copy( state.arcballState.cameraUp );
  // 	this.camera.near = state.arcballState.cameraNear;
  // 	this.camera.far = state.arcballState.cameraFar;

  // 	this.camera.zoom = state.arcballState.cameraZoom;

  // 	if ( this.camera is PerspectiveCamera ) {

  // 		this.camera.fov = state.arcballState.cameraFov;

  // 	}

  // 	this._gizmoMatrixState.fromArray( state.arcballState.gizmoMatrix.elements );
  // 	this._gizmoMatrixState.decompose( this._gizmos.position, this._gizmos.quaternion, this._gizmos.scale );

  // 	this.camera.updateMatrix();
  // 	this.camera.updateProjectionMatrix();

  // 	this._gizmos.updateMatrix();

  // 	this._tbRadius = this.calculateTbRadius( this.camera );
  // 	var gizmoTmp = new Matrix4().copy( this._gizmoMatrixState0 );
  // 	this.makeGizmos( this._gizmos.position, this._tbRadius );
  // 	this._gizmoMatrixState0.copy( gizmoTmp );

  // 	this.camera.lookAt( this._gizmos.position );
  // 	this.updateTbState( STATE2.IDLE, false );

  // 	this.dispatchEvent( _changeEvent );

  // }
}