Zoom to entity or Coordinate

Hi there,

Im working on a project where a previous developer decided to use a Cesium Widget rather than a Cesium Viewer for our map. But now I have to kind of reinvent the wheel and, basically implement the 'trackedEntity" on a cesium widget. Does anyone know how to override the zoom, to allow for a zoom to a Cartesian3 of an entity’s location?

You mean something like Camera.flyTo()?

Shown in this sandcastle.

not flyTo because I dont want the animation associated

From what I understand, you have an entity, you want

  1. the camera to focus on a point on/of this entity and
  2. the camera should be positioned near the entity (without any animations/zooms).

Camera.lookAt(targetPointCartesian3, offset) points towards the cartesian3 point (targetPointCartesian3) that you want the camera to focus at, and the position where you want to have the camera at is defined in the param “offset”. offset can be in terms of cartesian3 or headingPitchRange

1 Like

You can set the duration to 0, so it just jumps without animation.

But Chinmay’s idea might be even better.