copper3d / Modules / Controls/fitView
Module: Controls/fitView
Table of contents
Interfaces
Functions
Functions
fitView
▸ fitView(scene, preset, aspect, bounds, margin?): boolean
Returns false when there is nothing to do -- a preset whose eye sits exactly on its target has no direction to preserve.
Does NOT render. The caller decides when to draw, which matters under on-demand rendering where this may be one of several changes in a frame.
Parameters
| Name | Type |
|---|---|
scene | FitViewScene |
preset | CameraViewPreset |
aspect | number |
bounds | FitBounds |
margin? | number |
Returns
boolean