ToCart

From SCAR Divi Manual
Revision as of 23:40, 2 July 2011 by Freddy (talk | contribs) (Created page with "==Definition== <source lang="scar" lines="false"> function ToCart(Point: PPoint): TPoint; </source> ==Availability== SCAR Divi 3.00 > Current ==Description== Converts a given p...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Definition

function ToCart(Point: PPoint): TPoint;

Availability

SCAR Divi 3.00 > Current

Description

Converts a given polar coordinate defined by the PPoint Point to a cartesian coordinate defined by a Tpoint.

Example

var
  p: PPoint;
  tp: TPoint;

begin
  p.R := 1;
  p.T := 1;
  tp := ToCart(p);
  WriteLn('TPoint(' + IntToStr(tp.X) + ',' + IntToStr(tp.Y) + ')');
end.

Output:

TPoint(1,0)

See Also