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

Detailed Description

Specialist data layer for the display of CADRG & CIB data. The data layer allows CADRG/CIB data to be directly loaded into a data layer for display.

When displaying the CADRG/CIB data, the layer uses the following strategy to determine which coordinate system to use:

  • Use the user-defined coordinate system attached to the layer.
  • Use a default Dynamic Arc coordinate system.

This allows the CADRG/CIB data to be displayed with or without having to load a map and place it on the drawing surface.

Only rectangular coordinate systems can be used with the CADRG/CIB Data-layer as the raster data can not be reprojected at runtime.

Coordinate systems where the dateline has been shifted are supported. Tiles which cross the left and right boundaries will be drawn, however querying the latitude and longitude of the data will be dependent upon the coordinate system (i.e. result may not be valid).

If you attach a non rectangular coordinate system no error will be raised and an attempt will be made to display the tiles.

The layer no-longer attempts to use the Drawing Surface coordinate system as the CADRG/CIB data needs to be re-loaded if the coordinate system differs from the default.

The user is now expected to set the Coordinate System to be used if the default CADRG/CIB coordinate system is not to be used.

This can be achieved by the following code:

const TSLCoordinateSystem *coordSystem = m_mapDataLayer->queryCoordinateSystem();
m_cadrgDataLayer->setCoordinateSystem(coordSystem, false);
Definition tslcoordinatesystem.h:95

The following rendition styles are defined:

  • "dataextent" : Controls the drawing style for the Zone data extent boundary.
  • "scalelabel" : Controls the drawing style for the Scale label.
  • "frameextent" : Controls the drawing style for the Frame extent.
  • "framelabel" : Controls the drawing style for the Frame label.
  • "productextent" : Controls the drawing style for the overall Product extent rectangle.

Public Member Functions

 TSLCADRGDataLayer ()
 
bool addFrame (const char *filename, TSLCADRGScaleFactorEnum scale=TSLCadrgScaleFactorUndefined)
 
bool allFramesAdded (bool append=true)
 
void cacheSize (int maxCacheSize)
 
bool checkForZoneSwap (TSLTMC *x1, TSLTMC *y1, TSLTMC *x2, TSLTMC *y2)
 
void clearCache ()
 
bool containsRDTED ()
 
bool frameDUPerTMC (double &duX, double &duY)
 
TSLCADRGScaleFactorEnum getCurrentScale () const
 
TSLArcZoneEnum getCurrentZone () const
 
bool getDrawOverlapZone () const
 
bool getExtentOfFrameset (int idx, double &latBL, double &lonBL, double &latTR, double &lonTR)
 
TSLCADRGScaleFactorEnum getForcedScaleFactor ()
 
bool getFrame (TSLArcZoneEnum zone, TSLCADRGScaleFactorEnum scale, int framesetIndex, int index, TSLCADRGFrameFileInfo &frameInfo)
 
bool getMaxDisplayExtent (double *extent)
 
int getNumScaleFactors ()
 
int getNumFrames (int frameSetIndex) const
 
int getNumFrames (TSLArcZoneEnum zone, TSLCADRGScaleFactorEnum scale, int framesetIndex) const
 
int getNumScales (TSLArcZoneEnum zone) const
 
const char * getProduct () const
 
TSLCADRGScaleFactorEnum getScale (TSLArcZoneEnum zone, int index) const
 
TSLCadrgScaleFactorEnum getScaleFactor (int index)
 
bool getScaleFactorExtent (TSLCADRGScaleFactorEnum scaleFactor, double *blLatitude, double *blLongitude, double *trLatitude, double *trLongitude)
 
bool getScaleFactorThreshold (TSLCADRGScaleFactorEnum scaleFactor, double *upperThreshold, double *lowerThreshold)
 
bool getTMCExtentOfFrameset (int idx, TSLTMC *x1, TSLTMC *y1, TSLTMC *x2, TSLTMC *y2)
 
bool getTMCExtentOfFrameset (int idx, TSLEnvelope &extent, TSLEnvelope &extentRight, bool &split)
 
bool getTMCExtentOfFrameset (TSLArcZoneEnum zone, TSLCADRGScaleFactorEnum scale, int frameSetIndex, TSLEnvelope &extent, TSLEnvelope &extentRight, bool &split)
 
int getZoneOfFrameset (int framesetIndex)
 
void lowercaseFiles (bool flag)
 
int numFramesets ()
 
int numFramesets (TSLArcZoneEnum zone, TSLCADRGScaleFactorEnum scale)
 
const TSLCoordinateSystemqueryCoordinateSystem ()
 
bool removeFrame (const char *frameFile, bool recalculateExtent=true)
 
bool setCoordinateSystem (const TSLCoordinateSystem *coordinateSystem, bool ownsCoordinateSystem)
 
void setDrawOverlapZone (bool state)
 
bool setForcedScaleFactor (TSLCADRGScaleFactorEnum scaleFactor)
 
bool setMaxDisplayExtent (double extent)
 
bool setProduct (const char *product)
 
void setRDTEDRange (short min, short max)
 
bool setScaleFactorThreshold (TSLCADRGScaleFactorEnum scaleFactor, double upperThreshold, double lowerThreshold=0.0)
 
void * operator new (size_t size) TSL_NO_THROW
 
void * operator new (size_t size, char *filename, int line)
 
- Public Member Functions inherited from TSLDataLayer
void addDrawingCallback (TSLDataLayerDrawingCallback *drawingCallback)
 
bool addFeatureRendering (const char *featureName, TSLFeatureID featureID)
 
bool addLoader (TSLFileLoader *loader, TSLLoaderAppCallback callback, void *arg, TSLAllLoadedCallback allLoadedCallback=0, void *arg2=0)
 
bool addPathList (const TSLPathList *path_list)
 
void cancelFlashback ()
 
bool clearFeatureRendering (const char *featureName, TSLFeatureID featureID)
 
TSLDataHandlercreateDataHandler (const char *config_file=0)
 
TSLHistoryVersion currentVersion () const
 
TSLDataHandlerdataHandler ()
 
const TSLDataHandlerdataHandler () const
 
void destroy ()
 
bool entityIsVisible (const TSLEntity *entity, const TSLDrawingSurface *drawingSurface) const
 
const TSLFeatureClassListfeatureList () const
 
const TSLFeatureClassListfeatureList (const char *detailLayerName) const
 
bool fileModificationTime (const char *filename, TSLTimeType &lastModificationTime)
 
TSLEntityfindEntity (TSLTMC x, TSLTMC y, TSLTMC aperture, int depth, const char *featureName=0, int drawingSurfaceID=-1)
 
bool findFile (const char *filename, TSLSimpleString &foundPath) const
 
void flashbackToTimestamp (TSLHistoryTimestamp timestamp, TSLLayerArchiveCallback archiveCallback, void *arg=0)
 
void flashbackToTimestamp (TSLHistoryTimestamp timestamp, TSLLayerArchiveTileCallback archiveTileCallback, void *arg=0)
 
void flashbackToVersion (TSLHistoryVersion version, TSLLayerArchiveCallback archiveCallback, void *arg=0)
 
void flashbackToVersion (TSLHistoryVersion version, TSLLayerArchiveTileCallback archiveTileCallback, void *arg=0)
 
bool getActiveLayerName (const TSLEnvelope &extent, double screenResolution, TSLSimpleString &activeLayerName) const
 
TSLEntityIteratorgetEntityIterator (const char *detailLayer, TSLSelector *selector=NULL, TSLEnvelope *extent=NULL, bool splitOptimisedPrimitives=true)
 
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
 
TSLFileLoadergetLoader ()
 
bool getMUExtent (double *x1, double *y1, double *x2, double *y2, int drawingSurfaceID=-1) const
 
bool getTMCExtent (TSLTMC *x1, TSLTMC *y1, TSLTMC *x2, TSLTMC *y2, int drawingSurfaceID=-1) const
 
bool getUUExtent (double *x1, double *y1, double *x2, double *y2, const TSLDrawingSurface *drawingSurface) const
 
bool importHistory (TSLHistoryVersion mapVersion, TSLHistoryTimestamp timestamp, TSLHistoryImportSet *historySet)
 
bool latLongToTMC (double latitude, double longitude, TSLTMC *x, TSLTMC *y, bool local=false) const
 
bool latLongToTMC (int num, double *latitudes, double *longitudes, TSLTMC *xs, TSLTMC *ys, bool local=false) const
 
TSLDataLayerTypeEnum layerType () const
 
bool loadData (const char *filename)
 
bool loadRendering (const char *filename)
 
void notifyChanged (bool changed=true)
 
TSLMapQueryquery (TSLTMC x1, TSLTMC y1, TSLTMC x2, TSLTMC y2, int depth=-1, const char *featureName=NULL, int drawingSurfaceID=-1) const
 
TSLMapQueryquery (TSLTMC x1, TSLTMC y1, TSLTMC x2, TSLTMC y2, TSLSelector *selector, int drawingSurfaceID=-1) const
 
const TSLCoordinateSystemgetCoordinateSystem () const
 
bool queryVersionHistory (const TSLEnvelope &extent, TSLVersionHistorySet &history)
 
void refreshFlashback ()
 
bool removeData ()
 
void releaseResources (int surfaceID)
 
bool saveRendering (const char *filename, TSLMapLinkVersion ver=TSL_CURRENT_MAPLINK_VERSION)
 
bool setCoordinateSystem (const TSLCoordinateSystem *coordinateSystem)
 
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 TMCToLatLong (TSLTMC x, TSLTMC y, double *latitude, double *longitude, bool local=false, bool boundCheck=true) const
 
bool TMCToLatLong (int num, TSLTMC *xs, TSLTMC *ys, double *latitudes, double *longitudes, bool local=false) const
 
const TSLVersionHistorySetversionHistory () const
 

Constructor & Destructor Documentation

◆ TSLCADRGDataLayer()

TSLCADRGDataLayer::TSLCADRGDataLayer ( )

Member Function Documentation

◆ addFrame()

bool TSLCADRGDataLayer::addFrame ( const char * filename,
TSLCADRGScaleFactorEnum scale = TSLCadrgScaleFactorUndefined )

Provides the ability to add an individual frame file to the TSLCADRGDataLayer.

Once all the frame files have been added, the 'allFramesAdded' method must be called. Calling this method will then repopulate the data layer with the frames which were added via this method.

All frames added should be valid and conform to the RPF frame file naming convention.

Parameters
filenameThe full path to the CADRG frame file to load in the data layer.
scaleOptionally specify a scale at which the frame file should be added. If no scale is specified, the data layer will attempt to determine the scale of the frame file using the chart type.
Returns
true if the frame was successfully added to the data layer, false otherwise.

◆ allFramesAdded()

bool TSLCADRGDataLayer::allFramesAdded ( bool append = true)

This method should be called after all frames have been added to the data layer via the 'addFrame' method. Once called, the method will restructure the data layer and present the new frame files for use. If a frame file has been added more than once it will only appear in the data layer once, with the most recently added frame being stored.

The frames added to the data layer will be stored in a single frameset per scale in a zone.

Additionally, calling this method will clear the current cache.

Parameters
appendOptional argument to determine whether or not the frames added via the addFrame method should be appended to the frames residing in the layer. If 'false' is specified, the current contents of the data layer will be cleared and the added frames will replace them.
Returns
true on success, false otherwise.

◆ cacheSize()

void TSLCADRGDataLayer::cacheSize ( int maxCacheSize)

Set the maximum number of tiles to be held in the cache.

◆ checkForZoneSwap()

bool TSLCADRGDataLayer::checkForZoneSwap ( TSLTMC * x1,
TSLTMC * y1,
TSLTMC * x2,
TSLTMC * y2 )

Checks to see if displaying the specified extent would change the currently displayed zone. If so, then adjusts the extent to be in the correct position for the new projection.

The latitude/longitude of the extent centre are used to pick the zone and will be moved to the equivalent place in the new zone.

Returns True if the new extent would cause a buffer swap, False otherwise.

◆ clearCache()

void TSLCADRGDataLayer::clearCache ( )

Clears any CADRG frame files currently in the cache.

◆ containsRDTED()

bool TSLCADRGDataLayer::containsRDTED ( )

Returns true if the datalayer contains any RDTED data.

◆ frameDUPerTMC()

bool TSLCADRGDataLayer::frameDUPerTMC ( double & duX,
double & duY )

Queries the extent of a single pixel in the source raster in the same units as the extent of the layer.

Can be used to resize the drawing surface so that the raster in the datalayer is at its optimum size.

When the layer contains multiple scales, this function returns the pixel extent for the lowest resolution scale.

Returns true if successful.

◆ getCurrentScale()

TSLCADRGScaleFactorEnum TSLCADRGDataLayer::getCurrentScale ( ) const

Get the current scale of the data being presented on the data layer.

Before the current scale can be determined, a draw call must have been made.

Returns the current scale.

◆ getCurrentZone()

TSLArcZoneEnum TSLCADRGDataLayer::getCurrentZone ( ) const

Get the current zone of the data being presented on the data layer.

Before the current zone can be determined, a draw call must have been made.

Returns the current zone.

◆ getDrawOverlapZone()

bool TSLCADRGDataLayer::getDrawOverlapZone ( ) const

This method returns the state of the drawing of the overlap zone data.

◆ getExtentOfFrameset()

bool TSLCADRGDataLayer::getExtentOfFrameset ( int idx,
double & latBL,
double & lonBL,
double & latTR,
double & lonTR )

This method returns the latitude and longitude extent of the frameset.

Parameters
idxzero based index to the frameset. The number of framesets can be obtained by using noFramesets()
latBLBottom left latitude (degrees)
lonBLBottom left longitude (degrees)
latTRTop right latitude (degrees)
lonTRTop right longitude (degrees)
Returns
true if data has been returned, false otherwise.

◆ getForcedScaleFactor()

TSLCADRGScaleFactorEnum TSLCADRGDataLayer::getForcedScaleFactor ( )

Returns which scale the current layer has been forced to draw at.

If the returned value is TSLCadrgScaleFactorUndefined then no scale has been forced.

◆ getFrame()

bool TSLCADRGDataLayer::getFrame ( TSLArcZoneEnum zone,
TSLCADRGScaleFactorEnum scale,
int framesetIndex,
int index,
TSLCADRGFrameFileInfo & frameInfo )

Get frame information for the specified frame. To identify the frame file the zone, scale and frameset number must be passed.

Parameters
zoneThe zone the frame resides in.
scaleThe scale of the frame.
framesetIndexThe frameset the frame resides in. To retrieve the number of framesets, call the numFramesets() method with the zone and scale you wish to query the number of framesets from.
indexThe index of the frame to retrieve.
frameInfoA TSLCADRGFrameFileInfo object which will become populated with information pertaining to the specified frame.
Returns
true on success, false otherwise.

◆ getMaxDisplayExtent()

bool TSLCADRGDataLayer::getMaxDisplayExtent ( double * extent)

Get the maximum display extent in map units. This allows severe performance hits to be avoided by limiting the amount of data that can be drawn.

Parameters
extentThe current value in map units for the maximum display extent.
Returns
true on success, otherwise false.

◆ getNumFrames() [1/2]

int TSLCADRGDataLayer::getNumFrames ( int frameSetIndex) const

Retrieves the number of frames in the specified frameset.

A frameset should be limited to a particular zone but may contain multiple scales. This method returns the number of frame files contained in the specified frameset for all scales.

Parameters
frameSetIndexThe index of the frameset.

If the returned value is -1, it indicates that the specified frameset does not exist.

◆ getNumFrames() [2/2]

int TSLCADRGDataLayer::getNumFrames ( TSLArcZoneEnum zone,
TSLCADRGScaleFactorEnum scale,
int framesetIndex ) const

Retrieves the number of frames in the frameset for the specified zone and scale.

Parameters
zoneThe zone of the frameset.
scaleThe scale of the frameset.
framesetIndexThe index of the frameset.

If the returned value is 0, it indicates that the specified zone, scale and frameset are not populated in the data layer.

◆ getNumScaleFactors()

int TSLCADRGDataLayer::getNumScaleFactors ( )

Query the number of scale factors available in the current data.

◆ getNumScales()

int TSLCADRGDataLayer::getNumScales ( TSLArcZoneEnum zone) const

Returns the number of scales in the specified zone.

Parameters
zoneThe zone to retrieve the number of scales from.

If the returned value is 0, it indicates that the specified zone is not populated in the data layer.

◆ getProduct()

const char * TSLCADRGDataLayer::getProduct ( ) const

Returns the current value of the product text string contained within the product extent rectangle.

◆ getScale()

TSLCADRGScaleFactorEnum TSLCADRGDataLayer::getScale ( TSLArcZoneEnum zone,
int index ) const

Get the scale factor at the specified index in a zone.

Parameters
zoneThe zone to retrieve the scale from.
indexThe index of the scale to retrieve. To identify how many scales are in the current zone, call the getNumScales() method which is available on the data layer.

If the returned value is TSLCadrgScaleFactorUndefined it indicates that there was no scale identified at the specified location.

◆ getScaleFactor()

TSLCadrgScaleFactorEnum TSLCADRGDataLayer::getScaleFactor ( int index)

Get the nth scale factor available in the current data. Call getNumScaleFactors to determine how many scale factors are available.

Returns the nth scale factor.

◆ getScaleFactorExtent()

bool TSLCADRGDataLayer::getScaleFactorExtent ( TSLCADRGScaleFactorEnum scaleFactor,
double * blLatitude,
double * blLongitude,
double * trLatitude,
double * trLongitude )

Requests the extent of the specified scale.

Parameters
scaleFactorThe scale to query the extent for.
blLatitudeThe bottom left latitude of the extent.
blLongitudeThe bottom left longitude of the extent
trLatitudeThe top right latitude of the extent.
trLongitudeThe top right longitude of the extent.
Returns
true if the scale could be found and the extent is queryable.

◆ getScaleFactorThreshold()

bool TSLCADRGDataLayer::getScaleFactorThreshold ( TSLCADRGScaleFactorEnum scaleFactor,
double * upperThreshold,
double * lowerThreshold )

Allows the top and bottom thresholds for which a particular map scale is displayed to be queried.

Parameters
scaleFactorThe name of the map scale to query.
upperThresholdThe upper value in Map Units per Pixel.
lowerThresholdThe lower value in Map Units per Pixel.

Return true on success, false otherwise.

◆ getTMCExtentOfFrameset() [1/3]

bool TSLCADRGDataLayer::getTMCExtentOfFrameset ( int idx,
TSLEnvelope & extent,
TSLEnvelope & extentRight,
bool & split )

This method requests the extent of the area covered by the frameset indicated (idx).

In the case of a dateline shifted coordinate system and the frameset straddling the left and right edges the left and right extent are returned.

Parameters
idxzero based index to the frameset. The number of framesets can be obtained by using noFramesets()
extentThe extent of the frameset. With a dateline shifted coordinate system this will be the left most extent if split is true.
extentRightThe extent of the frameset to the right of the map. This will be the same as extent if the frameset has not been split by the map edge.
splitIf true indicates that the extent returned has been split by the map edge and that extentRight is valid and that extent is the extent on the left of the map.
Returns
true if data has been returned, false otherwise.

◆ getTMCExtentOfFrameset() [2/3]

bool TSLCADRGDataLayer::getTMCExtentOfFrameset ( int idx,
TSLTMC * x1,
TSLTMC * y1,
TSLTMC * x2,
TSLTMC * y2 )

This method requests the extent of the area covered by the frameset passed. The returned values will be in TMC

For a dateline shifted coordinate system this potentially returns the wrapped TMC extent. Please use the alternative form of the method which returns the two extents if the frameset straddles the left and right edges of the coordinate system.

Parameters
idxzero-based index to the frameset. The number if framesets can be obtained by using noFramesets()
(x1,y1)references to variables receiving the bottom left co-ordinate of the extent.
(x2,y2)references to variables receiving the top right co-ordinate of the extent.

◆ getTMCExtentOfFrameset() [3/3]

bool TSLCADRGDataLayer::getTMCExtentOfFrameset ( TSLArcZoneEnum zone,
TSLCADRGScaleFactorEnum scale,
int frameSetIndex,
TSLEnvelope & extent,
TSLEnvelope & extentRight,
bool & split )

This method requests the extent of the area covered by the frameset indicated (frameSetIndex) in the particular zone and scale.

In the case of a dateline shifted coordinate system and the frameset straddling the left and right edges the left and right extent are returned.

Parameters
zoneThe zone of the frameset.
scaleThe scale of the frameset.
frameSetIndexzero based index to the frameset. The number of framesets can be obtained by using noFramesets()
extentThe extent of the frameset. With a dateline shifted coordinate system this will be the left most extent if split is true.
extentRightThe extent of the frameset to the right of the map. This will be the same as extent if the frameset has not been split by the map edge.
splitIf true indicates that the extent returned has been split by the map edge and that extentRight is valid and that extent is the extent on the left of the map.
Returns
true if data has been returned, false otherwise.

◆ getZoneOfFrameset()

int TSLCADRGDataLayer::getZoneOfFrameset ( int framesetIndex)

Returns the zone number that the frameset resides in.

Returns -1 if the index or zone is invalid.

Return values are:

  • Zone H -> 0
  • Zone G -> 1
  • Zone F -> 2
  • Zone E -> 3
  • Zone D -> 4
  • Zone C -> 5
  • Zone B -> 6
  • Zone A -> 7
  • Zone 1 -> 8
  • Zone 2 -> 9
  • Zone 3 -> 10
  • Zone 4 -> 11
  • Zone 5 -> 12
  • Zone 6 -> 13
  • Zone 7 -> 14
  • Zone 8 -> 15

Polar Zones are not currently supported due to the projection required being different for other zones.

◆ lowercaseFiles()

void TSLCADRGDataLayer::lowercaseFiles ( bool flag)

Sets an internal flag to force conversion of all files and paths in subsequent table of contents files. This should be called before loading the relevant table of contents file.

The CADRG table of contents file is formatted assuming that the files will be read directly from a CDROM. As such, the names are ISO-9660 compliant and are all uppercase.

Some OS (eg. Solaris), are case-sensitive, but display these ISO-9660 files in lowercase. to perform conversion when searching for frame files. This method allows these to be read by converting the path and filenames when constructing the internal tables.

◆ numFramesets() [1/2]

int TSLCADRGDataLayer::numFramesets ( )

Returns the number of framesets in the datalayer.

◆ numFramesets() [2/2]

int TSLCADRGDataLayer::numFramesets ( TSLArcZoneEnum zone,
TSLCADRGScaleFactorEnum scale )

Returns the number of framesets in the specified scale of the specified zone.

Parameters
zoneThe zone the frameset resides in.
scaleThe scale of the frameset.

◆ operator new() [1/2]

void * TSLCADRGDataLayer::operator new ( size_t size)

◆ operator new() [2/2]

void * TSLCADRGDataLayer::operator new ( size_t size,
char * filename,
int line )

When included in an MFC application in debug mode, the debug new expects this to be here. Override it and return the same as the normal one. The library must include it when compiled in release mode, since the user's application may be in debug mode.

◆ queryCoordinateSystem()

const TSLCoordinateSystem * TSLCADRGDataLayer::queryCoordinateSystem ( )

Returns the coordinate system (if any) that has been attached to the data layer.

◆ removeFrame()

bool TSLCADRGDataLayer::removeFrame ( const char * frameFile,
bool recalculateExtent = true )

Remove a frame from the data layer. The frame must be present in the data layer before it can be removed. Frames added using addFrame will not be able to be removed unless allFramesAdded has been called.

Parameters
frameFileThe name of the frame file to remove, e.g. 0000A013.JN1
recalculateExtentAn optional flag to determine whether or not to recalculate the layer extents after removing the specified frame. This will ensure the frameset and layer extents are displayed correctly once the frame is removed.
Returns
true on success, false otherwise.

◆ setCoordinateSystem()

bool TSLCADRGDataLayer::setCoordinateSystem ( const TSLCoordinateSystem * coordinateSystem,
bool ownsCoordinateSystem )

Set the coordinate system for the data layer. Only Coordinate Systems without a projection are allowed. If the data layer has no coordinate system attached to it, it will use the coordinate system attached to the drawing surface. If no coordinate system is attached to the drawing surface then a default Dynamic Arc projection is used.

Parameters
coordinateSystemThe coordinate system to attach to the data layer.
ownsCoordinateSystemspecifies whether the data layer takes ownership of the coordinate system.
Returns
true on success. Returns false if the coordinate system couldn't be attached to the data layer, for example if the coordinate system has a projection.

◆ setDrawOverlapZone()

void TSLCADRGDataLayer::setDrawOverlapZone ( bool state)

This controls the drawing of the overlap zone. By default the overlap zone will not be drawn.

The overlap zone will only be drawn if its extent overlaps the drawing surface display extent.

This option is useful when displaying around a zone boundary where CADRG data will not normally be displayed when the layer switches the current zone.

The layer will draw the overlap zone first then the current zone.

Parameters
stateIf true the layer will draw the current zone and the overlap zone. If false the overlap zone will not be drawn.

◆ setForcedScaleFactor()

bool TSLCADRGDataLayer::setForcedScaleFactor ( TSLCADRGScaleFactorEnum scaleFactor)

Set the scale to be drawn by the TSLCADRGDataLayer.

Parameters
scaleFactorThe scale to be drawn at.
Returns
true if the scale could be found, false otherwise.

◆ setMaxDisplayExtent()

bool TSLCADRGDataLayer::setMaxDisplayExtent ( double extent)

Set the maximum display extent in map units. This allows severe performance hits to be avoided by limiting the amount of data that can be drawn.

Parameters
extentThe value in map units to set for the maximum display extent.
Returns
true on success, otherwise false.

◆ setProduct()

bool TSLCADRGDataLayer::setProduct ( const char * product)

Sets the product string which is displayed in the product extent rectangle. This value is automatically populated when loading CADRG/CIB data from an A.TOC file, however when adding individual frame files via the addFrame method it will require this value to be set. By default, the product string is set as "CADRG".

Parameters
productThe product string to display in the product extent rectangle.
Returns
true if the product string was set successfully, false otherwise.

◆ setRDTEDRange()

void TSLCADRGDataLayer::setRDTEDRange ( short min,
short max )

Sets the minimum and maximum range values for colouring the RDTED data.

The colours used to render the RDTED data are automatically chosen.

Data outside the defined range is clamped to the minimum or maximum value.

◆ setScaleFactorThreshold()

bool TSLCADRGDataLayer::setScaleFactorThreshold ( TSLCADRGScaleFactorEnum scaleFactor,
double upperThreshold,
double lowerThreshold = 0.0 )

Allows the top and bottom thresholds for which a particular map scale is displayed to be set.

Parameters
scaleFactorThe map scale to apply the changes to.
upperThresholdThe upper value in Map Units per Pixel.
lowerThresholdThe lower value in Map Units per Pixel. Defaulted to 0.0.

Return true on success, false otherwise.