CADability dotNET
Constructs a ModOp, that transforms the Src points to the Dst points. The length of Src and Dst must be equal and less than 5. If the length is 1, the resulting ModOp is a translation, if the length is 2, the parameter DoScale decides whether the resulting ModOp is a translation and rotation (DoScale==false) or translation, rotation and scaling (DoScale==true). If the length is 3 or 4, the resulting ModOp is any kind of an affinity, that projects the src points to the dst points.

Namespace: CADability
Assembly: CADability (in CADability.dll) Version: 1.1.4254.24737 (1.1.*)

Syntax

C#
public static ModOp Fit(
	GeoPoint[] Src,
	GeoPoint[] Dst,
	bool DoScale
)
Visual Basic
Public Shared Function Fit ( _
	Src As GeoPoint(), _
	Dst As GeoPoint(), _
	DoScale As Boolean _
) As ModOp
Visual C++
public:
static ModOp Fit(
	array<GeoPoint>^ Src, 
	array<GeoPoint>^ Dst, 
	bool DoScale
)

Parameters

Src
Type: array<CADability..::..GeoPoint>[]()[][]
source points
Dst
Type: array<CADability..::..GeoPoint>[]()[][]
destination points
DoScale
Type: System..::..Boolean
scaling if two point pairs are given

Return Value

resulting transformation

See Also