This document is archived and information here might be outdated. Recommended version. |
ArcObjects namespaces > SpatialAnalyst > ESRI.ArcGIS.SpatialAnalyst > Interfaces > IH > IHydrologyOp Interface > IHydrologyOp.FlowLength Method (ArcObjects .NET 10.4 SDK) |
Calculates distance, or weighted distance along a flow path.
[Visual Basic .NET] Public Function FlowLength ( _ ByVal directionRaster As IGeoDataset, _ ByVal downStream As Boolean, _ [ByRef weightRaster As Object] _ ) As IGeoDataset
[C#] public IGeoDataset FlowLength ( IGeoDataset directionRaster, bool downStream, ref object weightRaster );
Optional Values
[C++]
HRESULT FlowLength(
IGeoDataset* directionRaster,
VARIANT_BOOL downStream,
VARIANT* weightRaster,
IGeoDataset** FlowLength
);
[C++]
Parameters directionRaster [in]
directionRaster is a parameter of type IGeoDataset downStream [in] downStream is a parameter of type VARIANT_BOOL weightRaster [optional] weightRaster 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. FlowLength [out, retval]
FlowLength is a parameter of type IGeoDataset
directionRaster | raster indicating direction of flow
This grid is created using the IHydrologyOp::FlowDirection method. |
downStream | a Boolean indicating the direction of measurement along the flow path
If True, then the method calculates the downslope distance, along the flow path, from each cell to a sink or outlet on the edge of the raster. If False, the method calculates the longest upslope distance along the flow path, from each cell to the top of the drainage divide. |
[weightRaster] | a raster defining the impedance or resistance to move through each cell
The value at each cell location represents the cost per unit distance of moving through the cell. Each cell location value is multiplied by the cell resolution to obtain the total cost of passing through the cell. The data type for the weightRaster can be any Raster object that supports IGeoDataset (e.g., Raster, Raster band, etc.). |