MapLink Pro 11.1.1.0.
Envitia MapLink Pro: The Ultimate Mapping Application Toolkit
Loading...
Searching...
No Matches
TSLAcceleratedSurface Class Reference
Inheritance diagram for TSLAcceleratedSurface:

Detailed Description

Base class for the Accelerated Drawing surface.

The Accelerated Drawing Surfaces have been designed to allow rotation of raster data using either OpenGL or DirectX. This is achieved by rendering the buffered data layer information into tiles.

The tiles are then converted into textures and drawn using either OpenGL or DirectX.

The user should:

  1. Create an instance of a derived TSLAcceleratedRenderControl.
  2. Add this instance to a derived instance of this class.

The derived Accelerated Surface is responsible for creating an instance of TSLAcceleratedRender which is appropriate for the platform.

When a tile needs to be drawn, the surface will call via the TSLAcceleratedRenderControl the renderTile() method of a derived TSLAcceleratedRenderControl passing in a pointer to a TSLAcceleratedRenderer.

The client class will need to call renderTile() method on TSLAcceleratedRenderer (see class description).

Note that when using a TSLWMSDataLayer with the accelerated surface the user must ensure the setSynchronousLoading method has been called with the synchronousLoading parameter set to true.

Method Notes:

The method setDataLayerProps() controls the adding of maps to the background tile rendering thread.

If the TSLPropertyBuffered flag is set to true, the layer will be added to the background thread. If the value is set to false then the layer will not be added to the background thread and therefore not be drawn into the map tiles.

The Accelerated Custom Data Layer is never added to the background thread.

Performance Notes:

TSLObjectDataLayer's and TSLCustomDataLayer's should not be buffered with this surface as the tile caching will be defeated causing the tiles to be redraw for each frame.

The DirectX and OpenGL Surface supports intermixing normal drawing with varying performance impact.

If performance is the top requirement then use the TSLAcceleratedCustomDataLayer instead.

Look at the documentation for TSLAcceleratorConfiguration, TSLAcceleratedMTRenderer.

Limitations:

Rotate flags on symbols and text will not work as expected. The map tiles are drawn in the background thread unrotated.

The Interaction Modes magnifier mode does not work correctly with Accelerated Surfaces.

The number of tiles in the X-axis will need to be adjusted for Dynamic Arc maps.

The Accelerator Custom Data Layer is always drawn on top of the map tiles.

Runtime projected maps are not supported.

The Dynamics Object DataLayer instantiates the Display objects twice. Only one set is used for drawing.

Rotating a map/vector/raster data may introduce a slight degradation of image quality when compared to a standard 2D drawing surface. This is to do with the OpenGL/DirectX sampling of the pixels from the underlying textures. With the OpenGL versions you can reduce this effect by calling textureFilter Nearest with false on the TSLAcceleratorConfiguration.

TSLAcceleratedRenderer Limitations

Please see the TSLAcceleratedMTRenderControl and TSLAcceleratedBlockingRenderingControl

OpenGL Limitations:

While you can use wndResize to specify a smaller area to draw to, the whole window is given over to OpenGL. Therefore you will need to use an Accelerated Custom Data Layer to draw to the other parts of the window.

Double buffering of the drawing surface occurs by default and can not be disabled.

On Windows GDI rendering does not honour the alpha values of what is being drawn to. This affects patterned files where the transparent sections of the files becomes the background colour. This does not affect the X11 OpenGL variant.

OpenGL Requirements

Windows: OpenGL version 1.1, the extension GL_ARB_pixel_buffer_object will be used if present for faster GDI mixed drawing.

X11: OpenGL version 1.1, GLX version 1.3 and the extension GLX_EXT_texture_from_pixmap is required for Xlib mixed drawing.

See Also: TSLWGLAcceleratedSurface, TSLX11GLAcceleratedSurface, TSLDXAcceleratedSurface

Public Member Functions

virtual ~TSLAcceleratedSurface ()
 
virtual bool addRenderControl (TSLAcceleratedRenderControl *renderControl)
 
bool ADUsPerDU (double &xUnits, double &yUnits) const
 
bool ADUToLatLon (const double xADU, const double yADU, double &lat, double &lon, bool local=false) const
 
bool ADUToTMC (const double xADU, const double yADU, TSLTMC &xTMC, TSLTMC &yTMC) const
 
void displayCentre (double &x, double &y) const
 
bool displayScale (double &scaleX, double &scaleY) const
 
void getADUExtent (double *x1, double *y1, double *x2, double *y2) const
 
bool getConfiguration (TSLAcceleratorConfiguration &configuration) const
 
bool latLonToADU (const double lat, const double lon, double &xADU, double &yADU, bool local=false) const
 
bool setConfiguration (TSLAcceleratorConfiguration &configuration)
 
virtual void setOption (TSLOptionEnum option, bool value)
 
double TMCsPerADU () const
 
bool TMCToADU (const TSLTMC xTMC, const TSLTMC yTMC, double &xADU, double &yADU) const
 
double viewRotation () const
 
- Public Member Functions inherited from TSLDrawingSurface
bool clearAllRendering ()
 
bool clearDynamicColours ()
 
virtual TSLDrawingSurfaceclone (bool copyUserData=false)=0
 
TSLRasterBuffercreateRasterBuffer (unsigned int width, unsigned int height, TSLRasterBuffer::Format format, TSLRasterBuffer::FilterMode filterMode=TSLRasterBuffer::Linear)
 
bool declutterIsVisible (const char *feature_name, double resolution=0.0, const char *layer_name=0) const
 
bool drawDU (TSLDeviceUnits x1, TSLDeviceUnits y1, TSLDeviceUnits x2, TSLDeviceUnits y2, bool clear, bool updateExtentOnly=false)
 
bool drawUU (double x1, double y1, double x2, double y2, bool clear, bool updateExtentOnly=false)
 
bool DUToLatLong (TSLDeviceUnits x, TSLDeviceUnits y, double *latitude, double *longitude, bool local=false, bool boundCheck=true) const
 
bool DUToMU (TSLDeviceUnits x1, TSLDeviceUnits y1, double *x2, double *y2) const
 
bool DUToTMC (TSLDeviceUnits x1, TSLDeviceUnits y1, TSLTMC *x2, TSLTMC *y2) const
 
bool DUToUU (TSLDeviceUnits x1, TSLDeviceUnits y1, double *x2, double *y2) const
 
TSLEntityfindEntityDU (TSLDeviceUnits x, TSLDeviceUnits y, TSLDeviceUnits aperture, int depth, const char *feature_name=NULL)
 
TSLEntityfindEntityUU (double x, double y, double aperture, int depth, const char *feature_name=NULL)
 
TSLEntityfindSelectedEntityDU (TSLDeviceUnits x, TSLDeviceUnits y, TSLDeviceUnits aperture, int depth=-1, bool ignoreMapDataLayers=false)
 
TSLEntityfindSelectedEntityUU (double x, double y, double aperture, int depth=-1, bool ignoreMapDataLayers=false)
 
bool getColourIndices (int **indices, int *num)
 
TSLDataLayergetCoordinateProvidingLayer ()
 
const TSLDataLayergetCoordinateProvidingLayer () const
 
bool getDeclutterRange (const char *featureName, double *innerLimit, double *outerLimit, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool getDeviceCapabilities (int &horizontalSizeMM, int &verticalSizeMM, int &horizontalSizePixels, int &verticalSizePixels) const
 
bool getDeviceCapabilities (TSLDeviceCapabilities &capabilities) const
 
void getDUExtent (TSLDeviceUnits *x1, TSLDeviceUnits *y1, TSLDeviceUnits *x2, TSLDeviceUnits *y2) const
 
bool getFillStyleIndices (int **indices, int *num)
 
bool getFontStyleIndices (int **indices, int *num)
 
bool getLineStyleIndices (int **indices, int *num)
 
void getMUExtent (double *x1, double *y1, double *x2, double *y2) const
 
bool getSymbolStyleIndices (int **indices, int *num)
 
TSLDrawingSurfaceTiledBufferControlgetTiledBufferController ()
 
void getTMCExtent (TSLEnvelope &extent) const
 
void getUUExtent (double *x1, double *y1, double *x2, double *y2) const
 
bool getViewedLatLongRange (double *latitude, double *longitude, double *range, bool local=false, bool boundCheck=true) const
 
bool latLongToDU (double latitude, double longitude, TSLDeviceUnits *x, TSLDeviceUnits *y, bool local=false) const
 
bool latLongToMU (double latitude, double longitude, double *x, double *y, bool local=false) const
 
bool latLongToTMC (double latitude, double longitude, TSLTMC *x, TSLTMC *y, bool local=false) const
 
bool latLongToUU (double latitude, double longitude, double *x, double *y, bool local=false) const
 
bool MUToDU (double x1, double y1, TSLDeviceUnits *x2, TSLDeviceUnits *y2) const
 
bool MUToLatLong (double x, double y, double *latitude, double *longitude, bool local=false, bool boundCheck=true) const
 
bool MUToTMC (double x1, double y1, TSLTMC *x2, TSLTMC *y2) const
 
bool MUToUU (double x1, double y1, double *x2, double *y2) const
 
bool pan (double x1, double y1, bool auto_redraw=true)
 
bool pan (double x1, double y1, TSLDeviceUnits xDU, TSLDeviceUnits yDU, bool auto_redraw=true)
 
TSLMapQueryquery (const char *layerName, TSLTMC x1, TSLTMC y1, TSLTMC x2, TSLTMC y2, int depth=-1, const char *feature_name=NULL) const
 
TSLMapQueryquery (const char *layerName, TSLTMC x1, TSLTMC y1, TSLTMC x2, TSLTMC y2, TSLSelector *selector) const
 
bool redraw ()
 
bool reset (bool auto_redraw=true)
 
bool resize (double x1, double y1, double x2, double y2, bool auto_redraw=true, bool keep_aspect=false)
 
bool rotate (double angle)
 
double rotation () const
 
bool setDeclutterRange (const char *featureName, double innerLimit, double outerLimit, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool setDeviceCapabilities (const int horizontalSizeMM=0, const int verticalSizeMM=0, const int horizontalSizePixels=0, const int verticalSizePixels=0)
 
bool setDeviceCapabilities (const TSLDeviceCapabilities &capabilities)
 
void setRedrawCallback (TSLDrawingSurfaceDrawCallback *callback)
 
bool setupDynamicColours (const char *filename)
 
bool setViewedLatLongRange (double latitude, double longitude, double range, bool local=false, bool auto_redraw=true, bool keep_aspect=false)
 
void TMCperDU (double &xr, double &yr)
 
double TMCperUU ()
 
bool TMCToDU (TSLTMC x1, TSLTMC y1, TSLDeviceUnits *x2, TSLDeviceUnits *y2) const
 
bool TMCToLatLong (TSLTMC x, TSLTMC y, double *latitude, double *longitude, bool local=false, bool boundCheck=true) const
 
bool TMCToMU (TSLTMC x1, TSLTMC y1, double *x2, double *y2) const
 
bool TMCToUU (TSLTMC x1, TSLTMC y1, double *x2, double *y2) const
 
bool updateEntityExtent (TSLEntity *entity, const char *layerName)
 
void userUnitOrigin (double x_origin, double y_origin)
 
void userUnitOrigin (TSLUUEnum origin_enum)
 
void userUnits (double factor)
 
double userUnits ()
 
bool UUToDU (double x1, double y1, TSLDeviceUnits *x2, TSLDeviceUnits *y2) const
 
bool UUToLatLong (double x, double y, double *latitude, double *longitude, bool local=false, bool boundCheck=true) const
 
bool UUToMU (double x1, double y1, double *x2, double *y2) const
 
bool UUToTMC (double x1, double y1, TSLTMC *x2, TSLTMC *y2) const
 
bool wndResize (TSLDeviceUnits x1, TSLDeviceUnits y1, TSLDeviceUnits x2, TSLDeviceUnits y2, bool auto_redraw=true, TSLResizeActionEnum action=TSLResizeActionNone)
 
bool zoom (double percent, bool zoom_in, bool auto_redraw=true)
 
 TSLDrawingSurface ()
 
virtual ~TSLDrawingSurface ()
 
void clearSymbolList ()
 
void clearFontList ()
 
void clearLineList ()
 
void clearFillList ()
 
bool removeFillStyle (TSLStyleID style)
 
bool removeLineStyle (TSLStyleID style)
 
bool removeSymbolStyle (TSLStyleID style)
 
bool removeFontStyle (TSLStyleID style)
 
TSLStyleID createFontID (const TSLSimpleString &name, TSLFontType meaningOfName, int fontWeight, bool italic=false, bool underline=false, bool antiAliased=false, const unsigned char *memoryBlock=NULL, TSLSize memoryBlockSize=0)
 
TSLStyleID createStandardLineID (const unsigned char *pattern, TSLSize patternLength, int initialOffset, TSLLineScalingType scaleType)
 
TSLStyleID createSymbolLineID (int symbolID, double size=0.0, TSLDimensionUnits sizeUnits=TSLDimensionUnitsUndefined, float rotation=0.0f, double anchorPointX=0.0, double anchorPointY=0.0, TSLDimensionUnits anchorPointUnits=TSLDimensionUnitsUndefined)
 
TSLStyleID createStandardFillID (const unsigned char *pattern=NULL, TSLSize patternSizeInBytes=0, int patternXSize=0, int patternYSize=0)
 
TSLStyleID createSymbolFillID (int symbolID, double size=0.0, TSLDimensionUnits sizeUnits=TSLDimensionUnitsUndefined, float rotation=0.0f, double anchorPointX=0.0, double anchorPointY=0.0, TSLDimensionUnits anchorPointUnits=TSLDimensionUnitsUndefined)
 
TSLStyleID createSVGSymbolID (const TSLSimpleString &name, const unsigned char *memoryBlock=NULL, TSLSize memoryBlockSize=0)
 
TSLStyleID createFontSymbolID (const TSLSimpleString &name, TSLFontType meaningOfName, const unsigned char *memoryBlock=NULL, TSLSize memoryBlockSize=0)
 
TSLStyleID createRasterSymbolID (const TSLSimpleString &name, int xorigin, int yorigin, bool scaleable, const unsigned char *memoryBlock=NULL, TSLSize memoryBlockSize=0)
 
TSLStyleID createSymbolIDFromSymbol (TSLStyleID symbolID, int numberofColourPairs, const int *colourFrom, const int *colourTo)
 
- Public Member Functions inherited from TSLDrawingSurfaceBase
bool addDataLayer (TSLDataLayer *data_layer_interface, const char *data_id)
 
bool addDynamicRenderer (TSLDynamicRenderer *renderer, TSLFeatureID featureID=-1, const char *layerName=0)
 
bool addFeatureRendering (const char *featureName, TSLFeatureID featureID)
 
void attach (TSLDeviceContext handle)
 
void attach (TSLWindowHandle handle)
 
void attach (TSLDrawableHandle handle)
 
bool bringInFrontof (const char *move_data_layer, const char *target_data_layer)
 
bool bringToFront (const char *move_data_layer)
 
bool clearAllDeclutterData (const char *layer_name=0)
 
void clearAllDynamicRenderers ()
 
bool clearBackgroundColour ()
 
bool clearDeclutterData (const char *feature_name, const char *layer_name=0)
 
bool clearDynamicRenderer (TSLFeatureID featureID=-1, const char *layerName=0)
 
bool clearFeatureRendering (const char *featureName, TSLFeatureID featureID)
 
bool clearFrame ()
 
bool copyDeclutterData (const char *src_feature_name, const char *dest_feature_name, const char *src_layer_name=0, const char *dest_layer_name=0)
 
void detach ()
 
void detachAllDynamicRenderers ()
 
bool detachDynamicRenderer (TSLFeatureID featureID=-1, const char *layerName=0)
 
const char * featureClass (TSLFeatureID feature_id)
 
bool forceLayer (const char *data_id, const char *detail_layer_name)
 
bool getBackgroundColour (TSLStyleID *value)
 
bool getColourValue (int colour, unsigned char &r, unsigned char &g, unsigned char &b)
 
TSLDataLayergetDataLayer (const char *data_id)
 
bool getDataLayerInfo (int N, TSLDataLayer **dataLayer, const char **layerName) const
 
bool getDataLayerProps (const char *data_id, TSLPropertyEnum property_id, TSLPropertyValue *old_value)
 
bool getDeclutterStatus (const char *feature_name, TSLDeclutterStatusResultEnum *value, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool getDeclutterStatus (TSLFeatureID feature_id, TSLDeclutterStatusResultEnum *value, const char *dataLayerName, const char *detailLayerName=0)
 
TSLDynamicRenderergetDynamicRenderer (TSLFeatureID featureID=-1, const char *layerName=0)
 
bool getFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeInt attribute, int *result) const
 
bool getFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeDouble attribute, double *result) const
 
bool getFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeBool attribute, bool *result) const
 
bool getFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributes *result) const
 
int getNumDataLayers () const
 
bool getOption (TSLOptionEnum option)
 
void id (int id_)
 
int id () const
 
bool idleProcess ()
 
bool loadDeclutter (const char *filename)
 
bool loadRendering (const char *filename)
 
TSLPickResultSetpick (TSLDeviceUnits x, TSLDeviceUnits y, TSLDeviceUnits aperture, int depth, TSLPickSelector *selector=0)
 
TSLPickResultSetpick (const char *data_id, TSLDeviceUnits x, TSLDeviceUnits y, TSLDeviceUnits aperture, int depth=-1, TSLPickSelector *selector=0)
 
bool queryActiveLayer (const char *data_id, char *detail_layer_name, int detail_layer_name_size)
 
bool removeDataLayer (const char *data_id)
 
bool saveDeclutter (const char *filename, TSLMapLinkVersion ver=TSL_CURRENT_MAPLINK_VERSION)
 
bool saveRendering (const char *filename, TSLMapLinkVersion ver=TSL_CURRENT_MAPLINK_VERSION)
 
bool sendToBack (const char *move_data_layer)
 
bool sendToBackOf (const char *move_data_layer, const char *target_data_layer)
 
bool setBackgroundColour (int value)
 
bool setCoordinateProvidingLayer (const char *layer_name)
 
bool setDataLayerProps (const char *data_id, TSLPropertyEnum property_id, TSLPropertyValue new_value)
 
bool setDeclutterStatus (const char *feature_name, TSLDeclutterStatusEnum value, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool setDeclutterStatus (TSLFeatureID feature_id, TSLDeclutterStatusEnum value, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool setDeclutterStatusOnAllFeatures (TSLDeclutterStatusEnum value, const char *dataLayerName=0, const char *detailLayerName=0)
 
bool setFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeInt attribute, int value)
 
bool setFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeDouble attribute, double value)
 
bool setFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributeBool attribute, bool value)
 
bool setFeatureRendering (const char *featureName, TSLFeatureID featureID, TSLRenderingAttributes *value)
 
bool setFrame (int style, int colour, int thickness)
 
double TMCperMU ()
 
TSLDrawingSurfaceTypeEnum type () const
 
void userWord (void *ptr) const
 
void * userWord () const
 
bool cloneDynamicRenderersFrom (const TSLDrawingSurfaceBase *otherSurface)
 
void addDuplicateLayers (bool value)
 
virtual ~TSLDrawingSurfaceBase ()
 

Protected Member Functions

 TSLAcceleratedSurface ()
 
- Protected Member Functions inherited from TSLDrawingSurfaceBase
 TSLDrawingSurfaceBase ()
 

Protected Attributes

TSLAcceleratedRendererm_acceleratedRenderer
 
- Protected Attributes inherited from TSLDrawingSurfaceBase
void * m_classID
 

Additional Inherited Members

- Static Public Member Functions inherited from TSLDrawingSurface
static void cleanup ()
 
static bool copy (TSLDrawingSurface *copyTo, TSLDrawingSurface *copyFrom, bool copyUserData=false)
 
static TSLStyleID getIDOfNearestColour (int r, int g, int b)
 
static bool loadStandardConfig (const char *path=0, bool delayLoadIncludes=false)
 
static bool setupColours (const char *filename)
 
static bool setupFillStyles (const char *filename, bool delayLoadIncludes=false)
 
static bool setupFonts (const char *filename, bool delayLoadIncludes=false)
 
static bool setupLineStyles (const char *filename, bool delayLoadIncludes=false)
 
static bool setupSymbols (const char *filename, bool delayLoadIncludes=false)
 
static void disableAntiAliasFonts ()
 
static void enableAntiAliasFonts ()
 
- Static Public Member Functions inherited from TSLDrawingSurfaceBase
static bool addLoader (TSLFileLoader *loader)
 
static bool addPathList (TSLPathList *path_list)
 
static bool findFile (const char *filename, TSLSimpleString &foundPath)
 
static TSLFileLoadergetLoader ()
 

Constructor & Destructor Documentation

◆ ~TSLAcceleratedSurface()

virtual TSLAcceleratedSurface::~TSLAcceleratedSurface ( )
virtual

Destructor.

◆ TSLAcceleratedSurface()

TSLAcceleratedSurface::TSLAcceleratedSurface ( )
protected

Constructor.

Member Function Documentation

◆ addRenderControl()

virtual bool TSLAcceleratedSurface::addRenderControl ( TSLAcceleratedRenderControl * renderControl)
virtual

The classes derived from TSLAcceleratedRenderControl provide the user with a way of controlling how the map tiles are generated.

By default there are two mechanism's provided:

  1. Blocking, where by each call to render a map tile will block until the tile has been drawn (TSLAcceleratedBlockingRenderControl).
  2. Multi-threaded, where by a request is made and the tile is drawn in a separate thread (TSLAcceleratedMTRenderControl).
Parameters
renderControlChosen render control mechanism.
Returns
true if all is ok, false otherwise.
Note
The TSLAcceleratedSurface will take ownership the TSLAcceleratedRender Control.

◆ ADUsPerDU()

bool TSLAcceleratedSurface::ADUsPerDU ( double & xUnits,
double & yUnits ) const

Returns the number of Accelerator Device Units (ADU) per Device Units (DU, pixels).

Parameters
xUnitsnumber of ADU's per DU along the x-axis
yUnitsnumber of ADU's per DU along the y-axis
Returns
True if the values are set, otherwise false.

◆ ADUToLatLon()

bool TSLAcceleratedSurface::ADUToLatLon ( const double xADU,
const double yADU,
double & lat,
double & lon,
bool local = false ) const

Convert Accelerator Device Units to Latitude and Longitude.

These units are OpenGL device units not pixels.

Parameters
xADUx axis device unit to convert
yADUy axis device unit to convert
latconverted latitude
lonconverted longitude.
localIndicates whether the lat/long co-ordinate is in WGS84 or the local datum.
Returns
true on success, false otherwise.

◆ ADUToTMC()

bool TSLAcceleratedSurface::ADUToTMC ( const double xADU,
const double yADU,
TSLTMC & xTMC,
TSLTMC & yTMC ) const

Returns the TMC position of ADU point.

Parameters
xADUADU x position
yADUADU y position
xTMCreturned TMC x position
yTMCreturned TMC y position
Returns
true if the conversion was ok.

◆ displayCentre()

void TSLAcceleratedSurface::displayCentre ( double & x,
double & y ) const

Returns the center of the display in Map Units.

◆ displayScale()

bool TSLAcceleratedSurface::displayScale ( double & scaleX,
double & scaleY ) const

Returns the OpenGL scale factors applied.

This method should be used if you need to draw an object which is not distorted by the dynamic arc projection.

Parameters
scaleXScale factor for the x-axis
scaleYScale factor for the y-axis.
Returns

True if a scale is applied, false otherwise.

◆ getADUExtent()

void TSLAcceleratedSurface::getADUExtent ( double * x1,
double * y1,
double * x2,
double * y2 ) const

Query extent of data on TSLDrawingSurface.

This method allows the user to query the extent of the MapLink map data currently displayed in terms of ADU units, ignoring any rotation that has been applied to the drawing surface.

Note: If the user application maintains such extent, this method should be called to refresh them after any operation applied on the TSLDrawingSurface which will affect the area of Maplink map data displayed.

Parameters
(x1,y1)Storage for bottom left co-ordinate of the extent in ADU units.
(x2,y2)Storage for top right co-ordinate of the extent in ADU units.

◆ getConfiguration()

bool TSLAcceleratedSurface::getConfiguration ( TSLAcceleratorConfiguration & configuration) const

Gets the Texture tile rendering parameters.

Allows the user to query the current settings.

Parameters
configurationSettings returned.
Returns
True if the settings were obtained, False otherwise.

◆ latLonToADU()

bool TSLAcceleratedSurface::latLonToADU ( const double lat,
const double lon,
double & xADU,
double & yADU,
bool local = false ) const

Convert latitude and longitude to accelerator device units.

These units are OpenGL device units not pixels.

The points returned by latLonToADU are un-rotated points.

Parameters
latlatitude to convert.
lonlongitude to convert.
xADUx axis device unit position.
yADUy axis device unit position.
localIndicates whether the lat/long co-ordinate is in WGS84 or the local datum.
Returns
true on success, false otherwise.

◆ setConfiguration()

bool TSLAcceleratedSurface::setConfiguration ( TSLAcceleratorConfiguration & configuration)

Sets the Texture tile rendering parameters.

Allows the user to tune the parameters used to generate the texture tiles to suit the application and graphics card.

The settings will only affect tiles created after the call to this method. The current set of tiles will be invalidated and a redraw will need to be done.

Parameters
configurationSettings to use.
Returns
True if the settings were applied, False otherwise.

◆ setOption()

virtual void TSLAcceleratedSurface::setOption ( TSLOptionEnum option,
bool value )
virtual

Set option bitfield.

Parameters
optionEnumeration value specifying option to query
valueNew value for option flag.

Reimplemented from TSLDrawingSurfaceBase.

◆ TMCsPerADU()

double TSLAcceleratedSurface::TMCsPerADU ( ) const

Returns the number of TMCs per ADU for this drawing surface.

◆ TMCToADU()

bool TSLAcceleratedSurface::TMCToADU ( const TSLTMC xTMC,
const TSLTMC yTMC,
double & xADU,
double & yADU ) const

Returns the ADU position of a TMC point.

Parameters
xTMCTMC x position
yTMCTMC y position
xADUreturned ADU x position
yADUreturned ADU y position
Returns
true if the conversion was ok.

◆ viewRotation()

double TSLAcceleratedSurface::viewRotation ( ) const

Returns the 2D view rotation in degrees.

Member Data Documentation

◆ m_acceleratedRenderer

TSLAcceleratedRenderer* TSLAcceleratedSurface::m_acceleratedRenderer
protected