import { PerspectiveCamera , Vector3 } from "three" ; class export class Camera { private fov = 70 ; private readonly aspectRatio : number ; /**
     * Perspective camera setup
     */ private readonly perpCam : PerspectiveCamera ; private perpNearPane = 1 ; private perpFarPane = 100000 ; constructor ( container ) { this . aspectRatio = container . clientWidth / container . clientHeight ; this . perpCam = new PerspectiveCamera ( this . fov , this . aspectRatio , this . perpNearPane , this . perpFarPane ) ; this . perpCam . name = "perp" ; } public setCameraPosition ( positionX , positionY , positionZ ) { this . perpCam . position . x = positionX ; this . perpCam . position . y = positionY ; this . perpCam . position . z = positionZ ; this . perpCam . lookAt ( new Vector3 ( 0 , 0 , 0 ) ) ; } public getCamera ( ) { return this . perpCam ; } public getCameraPosition ( ) { return this . perpCam . position ; } public setAspect ( width , height ) { this . perpCam . aspect = width / height ; this . perpCam . updateProjectionMatrix ( ) ; } }