Show / Hide Table of Contents

Constructor Camera

Camera(double, double, double, double, double, double)

Initializes a new instance of the Camera class with the specified latitude, longitude, altitude, heading, pitch, and roll. The Camera's spatial reference will be WGS84.

Declaration
public Camera(double latitude, double longitude, double altitude, double heading, double pitch, double roll)
Parameters
Type Name Description
double latitude

The angular deltaDistance, measured in degrees north or south of the equator.

double longitude

The angular deltaDistance, usually expressed in degrees, minutes, and seconds, of the location of a point on the earth's surface east or west of an arbitrarily defined meridian (usually the Greenwich prime meridian).

double altitude

The altitude of the camera position in meters. If the altitude is below the BaseSurface and the NavigationConstraint is set to StayAbove, the camera will be located at the Surface. Note: that the default is StayAbove.

double heading

The angle around the z-axis at which the camera is rotated. The angle is clockwise from north in the East, North, Up (ENU) ground reference frame. The value is between 0 and 360, where 0 is looking North and 90 is looking East. Values are wrapped modulo 360 (for example, 370 becomes 10).

double pitch

The angle around the x-axis at which the camera is rotated in the East, North, Up (ENU) ground reference frame. The value is between 0 and 180, where 0 is looking straight down, 90 is looking towards the horizon, and 180 is looking straight up. Pitch values are clamped to this range: a negative value defaults to 0 and a value greater than 180 defaults to 180. If the behavior of a negative pitch is required, then the corresponding transformation with positive pitch can be set instead. For example, if heading:0 pitch:-20 roll:0 is required then heading:180 pitch:20 roll:180 can be used instead.

double roll

The angle around the y-axis (the direction of sight) at which the camera is rotated in the East, North, Up (ENU) ground reference frame. Positive values rotate counterclockwise in view space (for example, when looking north, 90 means the top of the screen points west). The value is between 0 and 360, where 0 is horizontal and 180 is upside down. Values are wrapped modulo 360 (for example, 370 becomes 10).

Exceptions
Type Condition
ArgumentException

Location or angular parameters have NAN values.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.3 - 200.8
.NET100.13 - 300.0
.NET Windows100.13 - 300.0
.NET Android200.0 - 300.0
.NET iOS200.0 - 300.0
.NET Framework100.0 - 200.8
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 200.8
Relevant samples
Change atmosphere effect: Changes the appearance of the atmosphere in a scene.
Scene layer selection: Identify features in a scene to select.

Camera(MapPoint, double, double, double)

Initializes a new instance of the Camera class with the specified location, heading, pitch, and roll. The Camera's spatial reference is derived from the locationPoint.

Declaration
public Camera(MapPoint locationPoint, double heading, double pitch, double roll)
Parameters
Type Name Description
MapPoint locationPoint

A point geometry defining the 3D location at which to place the camera. If the point has a spatial reference, the camera will adopt it. Otherwise, a spatial reference of WGS84 is assumed. If the point's z value is below the BaseSurface and the NavigationConstraint is set to StayAbove, the camera will be positioned at the Surface. Note that the default is StayAbove.

double heading

The angle around the z-axis at which the camera is rotated. The angle is clockwise from north in the East, North, Up (ENU) ground reference frame. The value is between 0 and 360, where 0 is looking North and 90 is looking East. Values are wrapped modulo 360 (for example, 370 becomes 10).

double pitch

The angle around the x-axis at which the camera is rotated in the East, North, Up (ENU) ground reference frame. The value is between 0 and 180, where 0 is looking straight down, 90 is looking towards the horizon, and 180 is looking straight up. Pitch values are clamped to this range: a negative value defaults to 0 and a value greater than 180 defaults to 180. If the behavior of a negative pitch is required, then the corresponding transformation with positive pitch can be set instead. For example, if heading:0 pitch:-20 roll:0 is required then heading:180 pitch:20 roll:180 can be used instead.

double roll

The angle around the y-axis (the direction of sight) at which the camera is rotated in the East, North, Up (ENU) ground reference frame. Positive values rotate counterclockwise in view space (for example, when looking north, 90 means the top of the screen points west). The value is between 0 and 360, where 0 is horizontal and 180 is upside down. Values are wrapped modulo 360 (for example, 370 becomes 10).

Exceptions
Type Condition
ArgumentException

Location or angular parameters have NAN values.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.3 - 200.8
.NET100.13 - 300.0
.NET Windows100.13 - 300.0
.NET Android200.0 - 300.0
.NET iOS200.0 - 300.0
.NET Framework100.0 - 200.8
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 200.8
Relevant samples
Add an integrated mesh layer: View an integrated mesh layer from a scene service.
List KML contents: List the contents of a KML file.

Camera(MapPoint, double, double, double, double)

Initializes a new instance of the Camera class based on a point to look at, the distance to this point, heading, pitch, and roll. The Camera's spatial reference is derived from the lookAtPoint.

Declaration
public Camera(MapPoint lookAtPoint, double distance, double heading, double pitch, double roll)
Parameters
Type Name Description
MapPoint lookAtPoint

The point in space the camera will be pointing at. If the point has a spatial reference, the camera will adopt it. Otherwise, a spatial reference of WGS84 is assumed.

double distance

The distance in meters between the lookAtPoint and the camera location.

double heading

The angle around the z-axis at which the camera is rotated. The angle is clockwise from north in the East, North, Up (ENU) ground reference frame. The value is between 0 and 360, where 0 is looking North and 90 is looking East. Values are wrapped modulo 360 (for example, 370 becomes 10).

double pitch

The angle around the x-axis at which the camera is rotated in the East, North, Up (ENU) ground reference frame. The value is between 0 and 180, where 0 is looking straight down, 90 is looking towards the horizon, and 180 is looking straight up. Pitch values are clamped to this range: a negative value defaults to 0 and a value greater than 180 defaults to 180. If the behavior of a negative pitch is required, then the corresponding transformation with positive pitch can be set instead. For example, if heading:0 pitch:-20 roll:0 is required then heading:180 pitch:20 roll:180 can be used instead.

double roll

The angle around the y-axis (the direction of sight) at which the camera is rotated in the East, North, Up (ENU) ground reference frame. Positive values rotate counterclockwise in view space (for example, when looking north, 90 means the top of the screen points west). The value is between 0 and 360, where 0 is horizontal and 180 is upside down. Values are wrapped modulo 360 (for example, 370 becomes 10).

Remarks

Note: the given values may mean that the point is not visible on screen. You can check its visibility using Esri.ArcGISRuntime.UI.Controls.SceneView.LocationToScreen(MapPoint).

Exceptions
Type Condition
ArgumentException

Location or angular parameters have NAN values.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.3 - 200.8
.NET100.13 - 300.0
.NET Windows100.13 - 300.0
.NET Android200.0 - 300.0
.NET iOS200.0 - 300.0
.NET Framework100.0 - 200.8
Xamarin.Android100.0 - 100.15
Xamarin.iOS100.0 - 100.15
UWP100.0 - 200.8
Relevant samples
Edit KML ground overlay: Edit the values of a KML ground overlay.
Feature layer rendering mode (scene): Render features in a scene statically or dynamically by setting the feature layer rendering mode.
Line of sight (location): Perform a line of sight analysis between two points in real time.

Camera(TransformationMatrix)

Initializes a new instance of the Camera class using a transformation matrix.

Declaration
public Camera(TransformationMatrix transformation)
Parameters
Type Name Description
TransformationMatrix transformation

The transformation matrix used to create the camera.

Remarks

This constructor assumes the input matrix already encodes a world-space camera pose. No additional origin mapping or translation scaling is applied by this constructor.

Use this constructor when your pose source already matches the scene's coordinate frame and distance scale. If your source pose is in a local frame, first resolve that local frame to world coordinates and apply any required translation scaling before creating the Camera.

Exceptions
Type Condition
ArgumentException

The X, Y, and Z translations must not be zero.

Applies to

Platforms and versions
TargetVersions
.NET Standard 2.0100.6 - 200.8
.NET100.13 - 300.0
.NET Windows100.13 - 300.0
.NET Android200.0 - 300.0
.NET iOS200.0 - 300.0
.NET Framework100.6 - 200.8
Xamarin.Android100.6 - 100.15
Xamarin.iOS100.6 - 100.15
UWP100.6 - 200.8
In this article
Provide feedback
Back to top Copyright © 2025 Esri.