BLUE
PHP 7.4.33
Path:
/var/www/uibuilder.cmshelp.dk/httpdocs/node_modules/three/src/cameras
Run
Logout
Edit File
Size: 2.32 KB
Close
/var/www/uibuilder.cmshelp.dk/httpdocs/node_modules/three/src/cameras/Camera.js
Text
Base64
import { WebGLCoordinateSystem } from '../constants.js'; import { Matrix4 } from '../math/Matrix4.js'; import { Object3D } from '../core/Object3D.js'; /** * Abstract base class for cameras. This class should always be inherited * when you build a new camera. * * @abstract * @augments Object3D */ class Camera extends Object3D { /** * Constructs a new camera. */ constructor() { super(); /** * This flag can be used for type testing. * * @type {boolean} * @readonly * @default true */ this.isCamera = true; this.type = 'Camera'; /** * The inverse of the camera's world matrix. * * @type {Matrix4} */ this.matrixWorldInverse = new Matrix4(); /** * The camera's projection matrix. * * @type {Matrix4} */ this.projectionMatrix = new Matrix4(); /** * The inverse of the camera's projection matrix. * * @type {Matrix4} */ this.projectionMatrixInverse = new Matrix4(); /** * The coordinate system in which the camera is used. * * @type {(WebGLCoordinateSystem|WebGPUCoordinateSystem)} */ this.coordinateSystem = WebGLCoordinateSystem; } copy( source, recursive ) { super.copy( source, recursive ); this.matrixWorldInverse.copy( source.matrixWorldInverse ); this.projectionMatrix.copy( source.projectionMatrix ); this.projectionMatrixInverse.copy( source.projectionMatrixInverse ); this.coordinateSystem = source.coordinateSystem; return this; } /** * Returns a vector representing the ("look") direction of the 3D object in world space. * * This method is overwritten since cameras have a different forward vector compared to other * 3D objects. A camera looks down its local, negative z-axis by default. * * @param {Vector3} target - The target vector the result is stored to. * @return {Vector3} The 3D object's direction in world space. */ getWorldDirection( target ) { return super.getWorldDirection( target ).negate(); } updateMatrixWorld( force ) { super.updateMatrixWorld( force ); this.matrixWorldInverse.copy( this.matrixWorld ).invert(); } updateWorldMatrix( updateParents, updateChildren ) { super.updateWorldMatrix( updateParents, updateChildren ); this.matrixWorldInverse.copy( this.matrixWorld ).invert(); } clone() { return new this.constructor().copy( this ); } } export { Camera };
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 0 × Files: 6
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
ArrayCamera.js
1.02 KB
lrw-r--r--
2025-03-28 11:04:37
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Camera.js
2.32 KB
lrw-r--r--
2025-03-28 11:04:37
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
CubeCamera.js
6.22 KB
lrw-r--r--
2025-03-28 11:04:38
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
OrthographicCamera.js
5.66 KB
lrwxr-xr-x
2025-03-28 11:04:38
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
PerspectiveCamera.js
10.39 KB
lrw-r--r--
2025-03-28 11:04:38
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
StereoCamera.js
3.87 KB
lrw-r--r--
2025-03-28 11:04:39
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).