OrbPro2 a Cesium distribution

TransformGizmo

new Cesium.TransformGizmo(scene, options)

Name Type Description
scene Scene The Cesium scene.
options object optional Options.
Name Type Default Description
entity Entity optional The entity to attach to.
showTranslate boolean true optional Show translation arrows.
showRotate boolean true optional Show rotation circles.
size number 300 optional Fixed world-space size of the gizmo in meters (arrow length ≈ 0.85 × size).
getModelMatrix function optional Optional callback(entity, time, result) returning an unscaled Matrix4 for the gizmo frame.
onTranslate function optional Callback(entity, newPosition) during translation.
onRotate function optional Callback(entity, newOrientation) during rotation.

Methods

static Cesium.TransformGizmo._circlePositions()

Generate positions for a circle of given radius in the plane perpendicular to the given axis (0=X → YZ, 1=Y → XZ, 2=Z → XY).

static Cesium.TransformGizmo._coneModelMatrix()

Local model matrix that translates + rotates a Z-aligned cone to sit at the tip of the given axis.
Build all polylines (arrow shafts and/or rotation circles) in a single PolylineCollection, plus cone head Primitive. Geometry is in local ENU coordinates (unit scale); the modelMatrix handles world positioning + scaling.
Find the parameter `s` on the axis line closest to a camera ray. Axis line: A(s) = P + s * D Ray: B(t) = O + t * R
End the active drag: restore the entity's position/orientation to a constant value (exit CallbackProperty) and re-enable the camera controller.
Called by the scene each frame. Uses PolylineCollection (dynamic modelMatrix) for lines and Primitive.modelMatrix for cones, so geometry only rebuilds when entity or show flags change — NOT when the camera moves.
Need help? The fastest way to get answers is from the community and team on the Cesium Forum.