Coordinate systems – Pitney Bowes MapXtreme User Manual

Page 305

Advertising
background image

Chapter 16: Spatial Objects and Coordinate Systems

Coordinate Systems

MapXtreme v7.1

312

Developer Guide

Dim multiPolygon As MultiPolygon = New _

MultiPolygon(coordSys,CurveSegmentType.Linear,points)


Dim insidePoint As DPoint = New DPoint(-0.115108,0.160671)
Dim boundaryPoint As DPoint = New DPoint(-0.446043,0.486811)
Dim outsidePoint As DPoint = New DPoint(-1.103118,0.021583)

If multiPolygon.ContainsPoint(insidePoint) Then _

Console.WriteLine("Points inside area inclosed by closed _
(GeometryDimension 2) objects are contained")

End If
If Not multiCurve.ContainsPoint(insidePoint) Then _

Console.WriteLine("But this is not true for linear _
(GeometryDimension 1) objects")

End If
If multiPolygon.ContainsPoint(boundaryPoint) Then _

Console.WriteLine("Points on the boundary of closed objects _
are contained")

End If
If multiCurve.ContainsPoint(boundaryPoint) Then _

Console.WriteLine("Points lying on linear objects are contained")

End If
If Not multiPolygon.ContainsPoint(outsidePoint) Then _

Console.WriteLine("Point completely outside closed objects _
are not contained")

End If
If Not multiCurve.ContainsPoint(outsidePoint) Then _

Console.WriteLine("Point completely outside linear objects _
are not contained")

End If

End Sub

Coordinate Systems

Coordinate systems describe the domain in which a particular object or set of objects reside. The
coordinate system allows for the delineation, in specific terms, of the object or objects being
described. The CoordSys classes contain methods, properties and interfaces that allow for the
creation, manipulation, and editing of coordinate systems.

When Geometries are created, they are created in a particular coordinate system specified in the
creation of the object. Objects cannot change the coordinate system in which they were created.
They can only be copied into another coordinate system.

The CoordSys class facilitates the creation and manipulation of coordinate systems. The Coordsys
class uses an XML version of the projection file (C:\Program Files\Common
Files\MapInfo\MapXtreme\7.x.x\MapInfoCoordinateSystemSet.xml).

Advertising