esri.ImageSpatialReference
Description
(Added at v3.14)
Defines the Image Coordinate System (ICS) for ImageServices. An ICS defines the spatial reference in terms of a primary image. A primary image displayed in its own image coordinate system exhibits no distortions; other images and features can be projected to overlap with the primary image using its image coordinate system.
Many imagery-centric workflows require displaying images in image coordinate systems instead of map coordinates (geographic or projected coordinate systems); for example, oblique images are distorted significantly when displayed in map coordinates but can be displayed nicely in a top-up view without distortions.
Samples
Search for
samples that use this class.
Class hierarchy
esri.SpatialReference
|_esri.ImageSpatialReference
Constructors
Properties
ics | Object | The full Image Coordinate System, which includes transformations and map spatial reference information specific to each image. |
icsid | Number | The OBJECTID of the image in a mosaic dataset. |
wkid | Number | The well-known ID of a spatial reference. |
wkt | String | The well-known text that defines a spatial reference. |
Methods
equals(inSR, sr) | Boolean | Tests whether the input image coordinate system equals the image coordinate system of the instance calling this method. |
isWebMercator() | Boolean | Returns true if the wkid of the spatial reference object is one of the following values: 102113, 102100, 3857. |
toJson(preserveUrl?) | Boolean | Converts the ImageSpatialReference instance to a JSON object. |
Constructor Details
Creates an instance of ImageSpatialReference.
Parameters:
<Object > params |
Required |
Options that may be passed into the constructor. See the object specification table below. |
params
properties:
<Object > ics |
Optional |
The full Image Coordinate System object, which includes transformations and map spatial reference information specific to each image. If this option isn't specified, then icsid must be specified. |
<Number > icsid |
Optional |
The OBJECTID of the image in a mosaic dataset. If this option isn't specified, then ics must be specified. |
<String > url |
Required |
The url of the image service. |
Property Details
The full Image Coordinate System, which includes transformations and map spatial reference information specific to each image.
The OBJECTID of the image in a mosaic dataset.
The well-known text that defines a spatial reference.
Method Details
Tests whether the input image coordinate system equals the image coordinate system of the instance calling this method.
Returns true if the wkid of the spatial reference object is one of the following values: 102113, 102100, 3857. (Added at v3.3)
Sample:
var sr = new esri.SpatialReference(102100);
console.log(sr.isWebMercator()); // true
Converts the ImageSpatialReference instance to a JSON object.
Parameters:
<Boolean > preserveUrl |
Optional |
Indicates whether to preserve the URL in the output JSON object. |