User Tools

Site Tools


api:dk11:delphi:gislayervector.tgis_shape.distance2part_tgis_point_double_integer_tgis_point

Table of Contents

TGIS_Shape.Distance2Part method

DK11 for Delphi | GisLayerVector.TGIS_Shape.Distance2Part | Constructors | Fields | Methods | Properties

Calculate the linear distance between a point and a part in the current shape..

Available also on: .NET | Java | ActiveX.

Syntax

// Delphi
public
  function Distance2Part(
    const _ptg : TGIS_Point;
    const _prec : Double;
    const _part : Integer;
    var _proj : TGIS_Point
  ) : Double; virtual; abstract;
// C++ Builder
public:
  virtual double Distance2Part(
    TGIS_Point* const _ptg,
    const double _prec,
    const int _part,
    TGIS_Point* &_proj
  ) = 0;

Parameters

Name Type Description
_ptg TGIS_Point reference point
_prec Double precision /not longer distance than/; point inside polygon is always not greater than _prec; if _prec less then 0 then being outside/inside polygon means the same;
_part Integer part number to which the distance will be computed
_proj TGIS_Point point projected to a nearest element of the shape

Result

Type Description
Double Distance in map units.
2020/05/07 01:09

Page Tools