Difference between revisions of "ATPADensity"

From SCAR Divi Manual
Jump to: navigation, search
(Created page with "==Definition== <source lang="scar" lines="false"> function ATPADensity(const ATPA: T2DPointArray): Extended; </source> ==Availability== SCAR Divi 3.28 > Current ==Description==...")
 
(No difference)

Latest revision as of 04:09, 23 October 2011

Definition

function ATPADensity(const ATPA: T2DPointArray): Extended;

Availability

SCAR Divi 3.28 > Current

Description

Calculates the density of a given T2DPointArray ATPA.

Example

var
  ATPA: T2DPointArray;
  w, h: Integer;

begin
  SetLength(ATPA, 3);
  ATPA[0] := [];
  ATPA[1] := [Point(1, 1), Point(2, 2)];
  ATPA[2] := [Point(5, 10)];
  WriteLn(ATPADensity(ATPA));
end.

Output:

16,6666666666667

See Also