Skip to content
Global and local scenes using different projections to display the same basemap layer and feature layer

What are global and local scenes?

Global and local scenes are different viewing modes you can use to visualize 3D data. When you work with a scene, you choose whether to render the data on a globe or to project it on a plane that can be navigated in 3D space.

A global scene is typically used to display data that spans around the globe when viewing the curvature of the earth is important.

A local scene is a projected view of a surface that is typically used for smaller extents. It is useful when visualizing data such as a country or a city. To show only a region of interest, you can clip a local scene to an extent.

A global scene generally displays data in a geographic coordinate system, while local scenes can only display data in projected coordinate systems.

In both global and local scenes, you can display data below the ground and navigate below and above the ground.

How to create a scene

To create a global or local scene, you define the basemap layer and data layers to display and then set the camera properties.

Define the scene

The first step is to create the scene with a basemap layer and/or data layers. You can also reference an elevation service to display the scene with relief.

ArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for .NETArcGIS Maps SDK for KotlinArcGIS Maps SDK for JavaArcGIS Maps SDK for SwiftArcGIS Maps SDK for QtCesiumJS
Expand
Use dark colors for code blocksCopy
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131  esriConfig.apiKey = "YOUR_ACCESS_TOKEN"  // In the ArcGIS Maps SDK for JavaScript, the Map class is used  // to define both maps and scenes.  const map = new Map({  basemap: "arcgis/light-gray",  ground: "world-elevation",  }) 

Set the camera

Now display the scene using a scene view. You set the scene view's perspective of the scene by defining the scene view's camera, specifying the camera's location (including height), heading, and tilt (or pitch).

If the API supports local scenes, you use the scene view to specify whether the viewing mode is local or global. .NET, Kotlin, Swift, Java and Qt APIs currently only support global scenes.

ArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for .NETArcGIS Maps SDK for KotlinArcGIS Maps SDK for JavaArcGIS Maps SDK for SwiftArcGIS Maps SDK for QtCesiumJS
Expand
Use dark colors for code blocksCopy
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131  const sceneView = new SceneView({  map: map,  camera: {  position: [-41.18215285, -86.13467977, 9321113.29449],  heading: 359.73,  tilt: 68.57,  },  viewingMode: "local", 

Code examples

Create a globe

This example displays earthquake data on a globe. The scene uses the Vintage Shaded Relief layer as a basemap. Additionally the earthquakes data layer is loaded as a CSV layer. .NET, Kotlin, Swift, Java and Qt API examples use a hosted feature layer. Set the scene on a scene view along with a camera position and a global viewing mode.

ArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for JavaScriptArcGIS Maps SDK for .NETArcGIS Maps SDK for KotlinArcGIS Maps SDK for JavaArcGIS Maps SDK for SwiftArcGIS Maps SDK for QtCesiumJS
Expand
Use dark colors for code blocksCopy
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132  const map = new Map({  basemap: new Basemap({  baseLayers: [  new TileLayer({  url: "https://tiles.arcgis.com/tiles/nGt4QxSblgDfeJn9/arcgis/rest/services/VintageShadedRelief/MapServer",  }),  ],  }),  layers: [csvLayer],  })   const view = new SceneView({  container: "viewDiv",  map: map,  // Indicates to create a global scene  viewingMode: "global",  camera: {  position: [-63.77153412, 20.75790715, 25512548.0],  heading: 0.0,  tilt: 0.1,  }, 

Create a local scene

This example displays earthquakes in a clipped, local scene. The scene view displays a basemap and earthquake data that is displayed below the ground plane. Enable navigation below the ground to permit exploring the earthquakes. Additionally, the view uses a clipping extent to display only the area of interest.

ArcGIS Maps SDK for JavaScript
Expand
Use dark colors for code blocksCopy
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172  const map = new Map({  basemap: "arcgis/topographic",  layers: [quakesDepthLayer],  ground: {  navigationConstraint: {  type: "none",  },  opacity: 0.8,  },  })   const view = new SceneView({  container: "viewDiv",  map: map,  // Indicates to create a local scene  viewingMode: "local",  // Use the exent defined in clippingArea to define the bounds of the scene  clippingArea: {  xmax: -10834217,  xmin: -10932882,  ymax: 4493918,  ymin: 4432667,  spatialReference: {  wkid: 3857,  },  },  camera: {  position: [-98.3640816, 36.4211506, 26124.42603],  heading: 32.37,  tilt: 78.08,  }, 

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.