Skip to main content

ignoreCenterOnFit

Typeboolean
Defaultfalse

When camera.fit is called, View3D will adjust camera with the model so that the model is not clipped from any camera rotation by assuming {@link View3D#center center} as origin of the rotation by default.
This will ignore that behavior by forcing model's bbox center as center of the rotation while fitting the camera to the model.

Example

{
src: "/egjs-view3d/model/draco/alarm.glb",
center: [
0.03,
0,
0
],
ignoreCenterOnFit: false
}
{
src: "/egjs-view3d/model/draco/alarm.glb",
center: [
0.03,
0,
0
],
ignoreCenterOnFit: true
}