public sealed class Raster : ArcGIS.Core.CoreObjectsBase, System.IDisposable
Public NotInheritable Class Raster Inherits ArcGIS.Core.CoreObjectsBase Implements System.IDisposable
public sealed class Raster : ArcGIS.Core.CoreObjectsBase, System.IDisposable
Public NotInheritable Class Raster Inherits ArcGIS.Core.CoreObjectsBase Implements System.IDisposable
The Raster object is a transient representation of raster data that can perform resampling and reprojection. It can be modified without affecting the source data. This allows the raster to represent what you want, as you may specify a projection, extent, and cell size into which the input data will be transformed. This makes the raster quite useful for performing display or analysis in a coordinate system different from that which is stored in the raster dataset. Because of the transient nature of the raster, any modifications that are made to this object will be lost when the object is released. The modified Raster can be persisted to another raster dataset on disk or in a geodatabase using the SaveAs method. A Raster is most easily understood as a vehicle to provide resampling, projection, and data type conversion from one or more raster bands to a desired output coordinate system.
A Raster can be obtained in the following ways:
var raster = MapView.Active.Map.GetLayersAsFlattenedList().OfType<RasterLayer>().FirstOrDefault(); if (raster != null) { await QueuedTask.Run(() => { var rasterTbl = raster.GetRaster().GetAttributeTable(); var cursor = rasterTbl.Search(); while (cursor.MoveNext()) { var row = cursor.Current; } }); }
System.Object
ArcGIS.Core.CoreObjectsBase
ArcGIS.Core.Data.Raster.Raster
Target Platforms: Windows 11, Windows 10