ArcObjects Library Reference (SpatialAnalyst)  

IDistanceOp.EucAllocation Method

Calculates for each cell the zone of the closest source cell (in Euclidean distance).

[Visual Basic .NET]
Public Function EucAllocation ( _
    ByVal sourceData As IGeoDataset, _
    [ByRef maxDistance As Object], _
    [ByRef valueRaster As Object] _
) As IGeoDataset
[C#]
public IGeoDataset EucAllocation (
    IGeoDataset sourceData,
    ref object maxDistance,
    ref object valueRaster
);
[C#]

Optional Values

maxDistance   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
valueRaster   To indicate that this parameter is undefined, first define a variable object Missing = Type.Missing; then pass this in as ref Missing.
[C++]
HRESULT EucAllocation(
  IGeoDataset* sourceData,
  VARIANT* maxDistance,
  VARIANT* valueRaster,
  IGeoDataset** allocation
);
[C++]

Parameters

sourceData [in]

  sourceData is a parameter of type IGeoDataset

maxDistance [optional]   maxDistance is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

valueRaster [optional]   valueRaster is a parameter of type VARIANT

  To indicate this parameter is undefined pass a reference to a VARIANT with type VT_ERROR and scode value of DISP_E_PARAMNOTFOUND.

allocation [out, retval]

  allocation is a parameter of type IGeoDataset

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server. Requires Spatial Analyst Extension.

Remarks

sourceData

an input Raster, RasterDataset, RasterBand, or RasterDescriptor or FeatureClass, FeatureClassDescriptor that identifies those cells or locations whose values are assigned to the output cell locations that they are closest to. For rasters, the input value type can be an integer type, string type, or floating point type if in_value_raster is used.

[maxDistance]

defines the threshold that the Euclidean distance values cannot exceed. If a cell is farther than the [maxDistance], the output value for the cell location will be NoData. The default distance is to the edge of the output Raster. The data type for maxDistance can be either integer or floating point.

[valueRaster]

an input Raster that identifies the values to associate with the source cell locations. The source cells define the zones that will be used in the Euclidean allocation calculations. The [valueRaster] is particularly important if the source Raster was created by the ILogicalOp::TEST method or a Boolean method that will only output 1 and 0, or if alternative values or zones are to be used instead of the existing ones on the source input. The data type for the valueRaster can be of type Raster, RasterDataset, RasterBand, or RasterDescriptor.

 

See Also

IDistanceOp Interface