MathTransform Constructor

public MathTransform(ClassType classType)

public MathTransform(const MathTransform &source)

 

Description

The MathTransform constructor creates a new instance of the MathTransform class.  The first signature for this constructor takes a single argument that specifies the type of the MathTransform, according to the ClassType enumeration.  The second constructor is a copy-constructor, which produces a MathTransform with the same value as the MathTransform passed as argument.

 

Example

void MathTransform_MathTransform()

{

GeoCalc.MathTransform mt(GeoCalc.MathTransform.ClassType.Affine);

mt.get_Parameters().set_FloatItem(L"dx", 0);

mt.get_Parameters().set_FloatItem(L"dxx", 1.5);

mt.get_Parameters().set_FloatItem(L"dxy", 1);

mt.get_Parameters().set_FloatItem(L"dy", 0);

mt.get_Parameters().set_FloatItem(L"dyy", 0.34);

mt.get_Parameters().set_FloatItem(L"dyx", 1);

 

GeoCalc.GeodeticPoint inPt(2);

inPt.set_InUnits(-1, 4);

GeoCalc.GeodeticPoint outPt(2);

if(! mt.Transform(inPt, outPt))

{

AfxMessageBox("Transform failed");

}

}