Table of Contents

Class RotationProjectionConverter

Namespace
ThinkGeo.Core
Assembly
ThinkGeo.Core.dll

This projection allows you to rotate the map image base don an angle.

public class RotationProjectionConverter : ProjectionConverter
Inheritance
RotationProjectionConverter
Inherited Members

Remarks

This can be usefully when you are working with directional maps such as driving maps where you want the upper center of the map to be in line with the direction of the vehicle heading.

Constructors

RotationProjectionConverter()

This is a constructor for the class.

public RotationProjectionConverter()

Remarks

This is the default constructor and will set the angle to 0 whick is north being up.

RotationProjectionConverter(double)

This is a constructor for the class.

public RotationProjectionConverter(double angle)

Parameters

angle double

This parameter is the angle you want to map to rotate to.

Remarks

This constructor allows you to pass in an angle to change the rotation of the map.

RotationProjectionConverter(double, GeographyUnit)

public RotationProjectionConverter(double angle, GeographyUnit sourceUnit)

Parameters

angle double
sourceUnit GeographyUnit

RotationProjectionConverter(GeographyUnit)

public RotationProjectionConverter(GeographyUnit sourceUnit)

Parameters

sourceUnit GeographyUnit

Properties

Angle

This property sets the angle of rotation.

public double Angle { get; set; }

Property Value

double

InternalProjectionUnit

public override GeographyUnit InternalProjectionUnit { get; }

Property Value

GeographyUnit

PivotCenter

public PointShape PivotCenter { get; set; }

Property Value

PointShape

Methods

ConvertToExternalProjectionCore(IEnumerable<Vertex>)

This method returns a projected vertices based on the coordinates passed in.

protected override Collection<Vertex> ConvertToExternalProjectionCore(IEnumerable<Vertex> verticies)

Parameters

verticies IEnumerable<Vertex>

Returns

Collection<Vertex>

This method returns a projected vertices based on the coordinates passed in.

Remarks

This method returns a projected vertex based on the coordinates passed in. You will need to override this method for the Projection class. Typically you can call the projection utility library that has interfaces for dozens of different types of projections.

ConvertToInternalProjectionCore(IEnumerable<Vertex>)

This method returns a de-projected vertices based on the coordinates passed in.

protected override Collection<Vertex> ConvertToInternalProjectionCore(IEnumerable<Vertex> verticies)

Parameters

verticies IEnumerable<Vertex>

Returns

Collection<Vertex>

This method returns a de-projected vertices based on the coordinates passed in.

Remarks

This method returns a de-projected vertex based on the coordinates passed in. You will need to override this method for the Projection class. Typically you can call the projection utility library that has interfaces for dozens of different types of projections. The de-projection is important because inside of the FeatureSource you will in many cases to to and from various projections.

GetUpdatedExtent(RectangleShape)

This method returns an adjusted extend based on the angle of rotation.

public RectangleShape GetUpdatedExtent(RectangleShape worldExtent)

Parameters

worldExtent RectangleShape

This parameter is the world extent before the rotation.

Returns

RectangleShape

This method returns an adjusted extend based on the angle of rotation.

Remarks

This method returns an adjusted extend based on the angle of rotation. It is important that you update your current extent every time you adjust the angle of the projection. This will ensure the rotaion is performed properly.

OpenCore()

protected override void OpenCore()