LuciadCPillar C# 2023.1.04
Luciad.Maps.Map.ViewMapTransformation Class Reference

This class allows to transform between view (pixel coordinates on the screen) and map coordinates. More...

Inheritance diagram for Luciad.Maps.Map.ViewMapTransformation:

Public Member Functions

void Dispose ()
 
Luciad.Cartesian.? Coordinate MapToView (Luciad.Geometries.Point point)
 Transform a point from the world reference to a coordinate in the view space. More...
 
Luciad.Geometries.Point ViewToMap (Luciad.Maps.Map.LocationMode locationMode, Luciad.Cartesian.Coordinate coordinate)
 Transform a coordinate from the view to a point in the world reference using the desired location mode. More...
 

Detailed Description

This class allows to transform between view (pixel coordinates on the screen) and map coordinates.

Unlike Camera, it takes into account what is visible on the screen. When transforming a point from view to map coordinates, this method will select the nearest visible surface. When transforming a point from map to view coordinates, it will take into account the visibility of that map point.

Warning
C# documentation translation is incomplete. You can find more information in the C++ documentation for luciad::Map::ViewMapTransformation.

Member Function Documentation

◆ Dispose()

void Luciad.Maps.Map.ViewMapTransformation.Dispose ( )
inline

◆ MapToView()

Luciad.Cartesian.Coordinate Luciad.Maps.Map.ViewMapTransformation.MapToView ( Luciad.Geometries.Point  point)
inline

Transform a point from the world reference to a coordinate in the view space.

If the point cannot be represented on the view, a std::nullopt is returned. This happens for example when the given world point lies behind the camera. Note: this method does not take into account whether a point is hidden by something else on the screen. It can for example transform point on the back of the globe to view coordinates.

point

the point in the map space.

the coordinate in the view space (device independent pixels), or std::nullopt.

InvalidArgumentException

when the point is not defined in the map reference.

Warning
C# documentation translation is incomplete. You can find more information in the C++ documentation for luciad::Map::ViewMapTransformation::mapToView.

◆ ViewToMap()

Luciad.Geometries.Point Luciad.Maps.Map.ViewMapTransformation.ViewToMap ( Luciad.Maps.Map.LocationMode  locationMode,
Luciad.Cartesian.Coordinate  coordinate 
)
inline

Transform a coordinate from the view to a point in the world reference using the desired location mode.

locationMode

the desired location mode.

LocationMode

coordinate

the point in the view space (device independent pixels)

the point on the Map, or std::nullopt when the given view point does not correspond to a point on the Map.

Warning
C# documentation translation is incomplete. You can find more information in the C++ documentation for luciad::Map::ViewMapTransformation::viewToMap.