Преглед на файлове

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

Removing unneeded function
David Catuhe преди 9 години
родител
ревизия
64ab51a04f
променени са 1 файла, в които са добавени 0 реда и са изтрити 23 реда
  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);
                 BABYLON.Vector3.TransformNormalToRef(this._defaultUpVector, this._cameraRotationMatrix, this.upVector);
             } else {
             } else {
                 Matrix.RotationYawPitchRollToRef(this.rotation.y, this.rotation.x, this.rotation.z, this._cameraRotationMatrix);
                 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;
             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
          * Override Camera.createRigCamera
          * Override Camera.createRigCamera
@@ -264,8 +243,6 @@
                         this.rotationQuaternion = new Quaternion();
                         this.rotationQuaternion = new Quaternion();
                     }
                     }
                     rigCamera._cameraRigParams = {};
                     rigCamera._cameraRigParams = {};
-                    rigCamera._cameraRigParams.vrActualUp = new Vector3(0, 0, 0);
-                    rigCamera._getViewMatrix = rigCamera._getVRViewMatrix;
                     rigCamera.rotationQuaternion = new Quaternion();
                     rigCamera.rotationQuaternion = new Quaternion();
                 }
                 }
                 return rigCamera;
                 return rigCamera;