* Copies the settings of the given camera. * * @param {Camera} camera - A camera.
(camera)
| 368 | */ |
| 369 | |
| 370 | copyCameraSettings(camera) { |
| 371 | |
| 372 | if(camera) { |
| 373 | |
| 374 | this.uniforms.cameraNear.value = camera.near; |
| 375 | this.uniforms.cameraFar.value = camera.far; |
| 376 | |
| 377 | if(camera instanceof PerspectiveCamera) { |
| 378 | |
| 379 | this.defines.PERSPECTIVE_CAMERA = "1"; |
| 380 | |
| 381 | } else { |
| 382 | |
| 383 | delete this.defines.PERSPECTIVE_CAMERA; |
| 384 | |
| 385 | } |
| 386 | |
| 387 | this.needsUpdate = true; |
| 388 | |
| 389 | } |
| 390 | |
| 391 | } |
| 392 | |
| 393 | /** |
| 394 | * Sets the resolution. |
no outgoing calls
no test coverage detected