Public Function ToPlane(ByVal inputPoint As GeoCalcNET.GeodeticPoint, ByVal outputPoint As GeoCalcNET.ProjectedPoint) As Boolean
public System.Boolean ToPlane(GeoCalcNET.GeodeticPoint inputPoint, GeoCalcNET.ProjectedPoint outputPoint)
The ToPlane method applies this Projection to the specified GeodeticPoint to produce the corresponding ProjectedPoint. The method takes two arguments, the first of which is the GeodeticPoint to be projected, and the second of which is the ProjectedPoint that will hold the result. The method returns a boolean value indicating the success of the operation.
Private Sub GeoCalcNET_Projection_ToPlane(ByVal proj As GeoCalcNET.Projection, ByVal data As GeoCalcNET.DataSourceComponent)
Dim gpt As GeoCalcNET.GeodeticPoint = data.GetGeodeticPoint("BMG", "GEODETIC_POINT_DEGREES")
gpt.SetInUnits(3.79, -15.8)
Dim ppt As GeoCalcNET.ProjectedPoint = data.GetProjectedPoint("BMG", "PROJECTED_POINT_METERS")
If Not proj.ToPlane(gpt, ppt) Then
MessageBox.Show("unable to perform conversion")
End If
End Sub
private void GeoCalcNET_Projection_ToPlane(GeoCalcNET.Projection proj, GeoCalcNET.DataSourceComponent data)
{
GeoCalcNET.ProjectedPoint ppt = data.GetProjectedPoint("BMG", "PROJECTED_POINT_METERS");
GeoCalcNET.GeodeticPoint gpt = data.GetGeodeticPoint("BMG", "GEODETIC_POINT_DEGREES");
gpt.SetInUnits(22.14, 45.06);
if(! proj.ToPlane(gpt, ppt))
{
MessageBox.Show("unable to project point onto plane");
}
}