Browse Source

Merge pull request #1190 from RaananW/target-camera-unneeded-code

Removing unneeded function
David Catuhe 9 years ago
parent
commit
64ab51a04f
1 changed files with 0 additions and 23 deletions
  1. 0 23
      src/Cameras/babylon.targetCamera.ts

+ 0 - 23
src/Cameras/babylon.targetCamera.ts

@@ -211,12 +211,6 @@
                 BABYLON.Vector3.TransformNormalToRef(this._defaultUpVector, this._cameraRotationMatrix, this.upVector);
             } else {
                 Matrix.RotationYawPitchRollToRef(this.rotation.y, this.rotation.x, this.rotation.z, this._cameraRotationMatrix);
-                //if (this.upVector.x !== 0 || this.upVector.y !== 1.0 || this.upVector.z !== 0) {
-                //    Matrix.LookAtLHToRef(Vector3.Zero(), this._referencePoint, this.upVector, this._lookAtTemp);
-                //    this._lookAtTemp.multiplyToRef(this._cameraRotationMatrix, this._tempMatrix);
-                //    this._lookAtTemp.invert();
-                //    this._tempMatrix.multiplyToRef(this._lookAtTemp, this._cameraRotationMatrix);
-                //}
             }
         }
 
@@ -237,21 +231,6 @@
             return this._viewMatrix;
         }
 
-        public _getVRViewMatrix(): Matrix {
-            this._updateCameraRotationMatrix();
-
-            Vector3.TransformCoordinatesToRef(this._referencePoint, this._cameraRotationMatrix, this._transformedReferencePoint);
-            Vector3.TransformNormalToRef(this._defaultUpVector, this._cameraRotationMatrix, this._cameraRigParams.vrActualUp);
-
-            // Computing target and final matrix
-            this.position.addToRef(this._transformedReferencePoint, this._currentTarget);
-
-            Matrix.LookAtLHToRef(this.position, this._currentTarget, this._cameraRigParams.vrActualUp, this._cameraRigParams.vrWorkMatrix);
-
-            this._cameraRigParams.vrWorkMatrix.multiplyToRef(this._cameraRigParams.vrPreViewMatrix, this._viewMatrix);
-            return this._viewMatrix;
-        }
-
         /**
          * @override
          * Override Camera.createRigCamera
@@ -264,8 +243,6 @@
                         this.rotationQuaternion = new Quaternion();
                     }
                     rigCamera._cameraRigParams = {};
-                    rigCamera._cameraRigParams.vrActualUp = new Vector3(0, 0, 0);
-                    rigCamera._getViewMatrix = rigCamera._getVRViewMatrix;
                     rigCamera.rotationQuaternion = new Quaternion();
                 }
                 return rigCamera;