You can navigate scene A scene is a collection of layers that are displayed in 3D. It is typically composed of a basemap layer, data layers, and 3D data. Learn more views (SceneView or LocalSceneView) by:

Built-in navigation

The scene views have a number of built-in gestures that allow you to navigate a scene using the mouse, touch screen, or keyboard.

Basic navigation

Navigation for scene views is essentially the same as navigation for a map view. Navigation in a scene view moves the position of a camera in 3D space and therefore has some subtle differences. The following table summarizes the built-in navigation capabilities of the SceneView and LocalSceneView control.

NavigationMouseTouchKeyboard
Pan    • Hold left button and drag    • Drag
      Drag gesture
    • Flick
      Flick gesture
  • ←↑→↓: Move the camera in the direction of the arrow
  •Shift+←↑→↓ (iOS only): Move the camera in the direction of the arrow when in full keyboard mode
Zoom in    • Scroll wheel forward    • Spread
      Spread gesture
    • Double tap
      Double tap gesture
  • +: Zoom in on the view center
  • J: Lower the camera elevation
Zoom out                       • Scroll wheel backward    • Pinch
      Pinch gesture
  • -: Zoom out from the view center
  • U: Raise the camera elevation
Rotate    • Hold right button and drag right or left    • Multiple fingers drag left/right        
      Multiple finger drag left/right gesture
  • A: Rotate camera counterclockwise
  • D: Rotate camera clockwise
  • N: Reset heading to north
  • Alt+: Rotate camera counterclockwise
  • Alt+: Rotate camera clockwise
  • Alt+: Reset heading to north

  * On Mac, use Option rather than Alt
Change pitch    • Hold right button and drag up or down    • Multiple fingers drag up/down
      Multiple finger drag up/down gesture
  •W: Pitch up
  •S: Pitch down
  •P: Reset pitch

Navigating a scene view on a touch screen warrants some additional details.

There are three navigation modes available using touch: pan mode (single finger), zoom and pan mode (multiple finger), and rotate and pitch mode (multiple finger). For single finger pan, place one finger on the screen. For pan and zoom mode, spread, pinch, or drag two or more fingers. For heading and pitch mode, place multiple fingers on the screen and move with a consistent distance between your fingers. The following list describes the touch gestures used to execute navigation operations in each mode.

  • Pan mode (single finger)
    • Drag: Pans
    • Flick: Pans
  • Pan and zoom mode (multiple fingers)
    • Spread: Zooms in
    • Pinch: Zooms out
    • Drag: Pans
    • Pivot: Rotates
  • Heading and pitch mode (multiple fingers)
    • Drag up and down: Changes pitch
    • Drag left and right: Changes heading

Programmatically change camera position

Your applications can programmatically navigate a 3D scene by creating a new camera and setting it to the view you are working with. A camera defines the location from which you are viewing the scene.

Camera position for a scene view

The camera is shown in this image for illustration purposes; when you set camera settings (location, pitch), think of the camera class as a real-life camera you’re adjusting the position of.

Set the camera

For example, to point the camera to toward the Snowdon mountainside, use these values:

  • For 3D location, use 53.06 latitude, -4.04 longitude, 1289 meters above sea level
  • For heading, use 295 degrees
  • For pitch, use 71 degrees
  • For roll, use 0 degrees
var snowdonCamera = new Camera(53.06, -4.04, 3289, 295, 71, 0);

Surface elevation applied to a scene

Apply the new camera to the scene view using SceneView.SetViewpointCamera(), or animate the transition to it with SceneView.SetViewpointCameraAsync(Camera, TimeSpan).

MySceneView.SetViewpointCamera(snowdonCamera);

Move and adjust the camera

After you set a camera, you can update the scene view display by creating and applying a new camera. You can define the new camera with absolute values for location and orientation, or derive it from the current camera using relative values.

For example, using the relative approach, your code can preserve the current camera location, pitch, and roll, but rotate the heading by 45 degrees.

// Get the current camera from the SceneView.
var currentCamera = MySceneView.Camera;
// Create a new camera with the same location, pitch, and roll.
// Change the heading by 45 degrees.
var updatedCamera = new Camera(
currentCamera.Location,
currentCamera.Heading + 45.0,
currentCamera.Pitch,
currentCamera.Roll
);
// Set the SceneView's viewpoint with the new camera.
MySceneView.SetViewpointCamera(updatedCamera);

Use the SceneView.Camera property to get the scene view’s current viewpoint camera. To adjust the viewpoint relative to the camera’s current position or orientation, use the current camera to create a new camera, then apply the new camera with SceneView.SetViewpointCamera().