VR-Forces 4.8 Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes
makVrf::DtVrfTerrain Class Reference

Extension of DtVrvTerrain that sends a signal when the terrain is set from record. More...

Inheritance diagram for makVrf::DtVrfTerrain:
Inheritance graph
[legend]

Public Member Functions

 DtVrfTerrain (makVrv::DtDe &de, makVrv::DtAgentManagerInterface &sceneManagerInterface)
 CTOR. More...
 
virtual ~DtVrfTerrain ()
 DTOR. More...
 
virtual void setFromRecord (const makArchives::DtTerrainRecord &r, bool clearFirst)
 Populate a DtTerrain from a DtTerrainRecord. More...
 
virtual const
makArchives::DtTerrainRecord::GenericRecords
navigationAreas () const
 
virtual void removeNavigationArea (const std::string &)
 
virtual void addNavigationArea (const std::string &area)
 
virtual void addNavigationArea (const makArchives::DtGenericTerrainRecord &record)
 
virtual void changeNavigationAreaPath (const std::string &from, const std::string &to)
 
virtual bool hasNavigationArea (const DtFilename &) const
 
bool navigationAreasModified () const
 
virtual void clearNavigationAreasModified ()
 
virtual void clearNavigationAreas ()
 
virtual void getRecord (makArchives::DtTerrainRecord &rec)
 Fill out a DtTerrainRecord with the current terrain info. Called by saveTerrain(). More...
 
virtual makVrv::DtFeatureLayerfindFeatureLayerNoPath (const std::string &featureLayerFilename)
 Strips the path off the feature layers to see if the given name matches. More...
 
virtual const DtFilename & simulationTerrain () const
 
virtual bool navigationAreasAreOnSimulationTerrain () const
 
virtual std::string navigationAreaTerrainFilename () const
 Returns the filename of the terrain to use for navigation area generation. More...
 
virtual void getSimulationTerrainRecord (makArchives::DtTerrainRecord &) const
 
virtual bool loadSimulationTerrain (const DtFilename &)
 Loads the simulation terrain given by the filename. More...
 
virtual void clearSimTerrain ()
 Clears simulation terrain only. If the simulation terrain flag is not set then message will not be sent out for clearing navigation areas. More...
 
virtual void clearGuiTerrain ()
 Clears the gui terrain. If there is no sim terrain loaded will also signal navigation areas cleared. More...
 
virtual void setSignalNewNavigationAreas (bool)
 When loading a terrain, whether or not to signal that the navigation areas are updated. More...
 
bool signalNewNavigationAreas () const
 
virtual
makVrv::DtCoordinateSystem
navigationAreasCoordinateSystem () const
 Returns the coordinate system used by the navigation area. More...
 
virtual void signalNavigationAreasUpdated ()
 Call to signal out navigation areas set signal. More...
 
- Public Member Functions inherited from makVrv::DtTerrain
 DtTerrain (DtDe &de, DtAgentManagerInterface &sceneManagerInterface)
 CTOR. More...
 
virtual ~DtTerrain ()
 DTOR. More...
 
void clear (bool reload=false)
 Clear the terrain. More...
 
bool isPropNameUsed (const std::string &propName) const
 Checks whether a prop name is in use. More...
 
virtual bool getTerrainIntersection (double x, double y, double z, double upX, double upY, double upZ, double &retX, double &retY, double &retZ)
 Get the closest intersection to x,y,z. More...
 
virtual void clearElevationCache ()
 If any of the terrain's patch objects is using an elevation cache, clear them (otherwise do nothing). More...
 
virtual const std::string * findOptionalParameter (const std::string &name) const
 Find an optional parameter. More...
 
virtual void setOptionalParameter (const std::string &name, const std::string &value)
 Set an optional parameter. More...
 
virtual void setOptionalParameters (const makArchives::DtTerrainRecord::OptionalParameterMap &)
 Set an optional parameters. More...
 
virtual void removeOptionalParameter (const std::string &name)
 Remove an optional parameter. More...
 
const
makArchives::DtTerrainRecord::OptionalParameterMap
optionalParameters () const
 Get the optional parameters. More...
 
virtual const std::string & description ()
 Get the terrains's description. More...
 
virtual void setDescription (const std::string &description)
 Set the terrains's description. More...
 
virtual bool useICO () const
 Get the UseICO flag. More...
 
virtual void setUseICO (bool flag)
 Set the UseICO flag. More...
 
virtual unsigned int maxPagedLODs () const
 Get max paged LOD target. More...
 
virtual void setMaxPagedLODs (unsigned int maxPagedLODs)
 Set the max paged LOD target. More...
 
virtual bool reloadingTerrain ()
 is the terrain currently reloading More...
 
bool globalScaleTerrain () const
 Checks to see if the terrain is a global scale terrain. More...
 
void updateGlobalScaleTerrain ()
 Rechecks if the terrain is of global scale. More...
 
virtual void reloadTerrain ()
 Request that the current terrain be reloaded. More...
 
virtual DtTerrainPatchaddTerrainPatch (const makArchives::DtTerrainPatchRecord &rec)
 Create and add a new terrain patch driver. More...
 
virtual DtTerrainPatchaddTerrainPatch (const std::string &terrainDefinitionName, bool minimapOnly=false)
 Create and add a new terrain patch driver. More...
 
virtual DtTerrainPatchfindTerrainPatch (const std::string &terrainDefinitionName)
 Return the DtTerrainPatchObjectAgent with the name terrainName. More...
 
virtual DtTerrainPatchfindTerrainPatch (DtUniqueID id)
 Return the DtTerrainPatchObjectAgent with the unique id. More...
 
virtual bool removeTerrainPatch (const std::string &terrainDefinitionName)
 Find and delete a terrain. More...
 
const TerrainPatchesterrainPatches () const
 Get the terrain drivers. More...
 
TerrainPatchesterrainPatches ()
 Get the terrain drivers. More...
 
bool lightPointsEnabled () const
 Are we showing point lights on the terrain? More...
 
virtual const
TerrainOperationsMap
terrainOperationsMap () const
 
virtual DtFeatureLayeraddFeatureLayer (const makArchives::DtFeatureLayerRecord &rec, makArchives::DtTerrainOperationRecord::TargetApplication target=makArchives::DtTerrainOperationRecord::VisualizationAndSimulation)
 Add a feature layer. More...
 
virtual DtFeatureLayeraddFeatureLayer (const std::string &featureLayerFilename, makArchives::DtTerrainOperationRecord::TargetApplication target=makArchives::DtTerrainOperationRecord::VisualizationAndSimulation)
 Create and add a DtFeatureLayer. More...
 
virtual void removeFeatureLayer (const std::string &featureLayerFilename)
 Remove a feature layer. Emits signal_terrainPatchToBeDeleted. More...
 
virtual const FeatureLayersfeatureLayers () const
 Accessor for FeatureLayers. More...
 
virtual FeatureLayersfeatureLayers ()
 Accessor for FeatureLayers. More...
 
virtual DtFeatureLayerfindFeatureLayer (const std::string &featureLayerFilename)
 Return the DtFeatureLayer with the name featureLayerFilename. More...
 
virtual DtStreamedFeatureLayerstreamedFeatureLayer ()
 return the streamed feature layer More...
 
virtual DtBuoyBeaconLayerbuoyBeaconLayer ()
 Return the buoy layer. More...
 
virtual DtDynamicFeatureLayerdynamicFeatureLayer ()
 Return the dynamic feature layer. More...
 
virtual DtNavigationLightManagernavigationLightManager ()
 Return the nav light manager. More...
 
virtual
DtNavigationFeatureManager
navigationDaymarkManager ()
 Return the nav daymark manager. More...
 
virtual
DtNavigationFeatureManager
navigationTopmarkManager ()
 Return the nav topmark manager. More...
 
virtual DtOceanLayeraddOceanLayer (const makArchives::DtOceanLayerRecord &rec)
 Add an ocean layer. More...
 
virtual DtOceanLayeraddOceanLayer (const std::string &layerName)
 Create and add a DtOceanLayer. More...
 
virtual void removeOceanLayer (const std::string &layerName)
 Remove a ocean layer. Emits signal_oceanLayerToBeDeleted. More...
 
virtual const OceanLayersoceanLayers () const
 Accessor for OceanLayers. More...
 
virtual OceanLayersoceanLayers ()
 Accessor for OceanLayers. More...
 
virtual DtOceanLayerfindOceanLayer (const std::string &layerName)
 Return the DtOceanLayer with the name layerName. More...
 
virtual void onOceanNodesExtracted (DtTerrainPatchObject &patchObject)
 Slot called when ocean nodes are extracted. More...
 
std::string generatePropName (const std::string &propType)
 Generate a unique name for the prop. More...
 
virtual DtForestforest ()
 Return the DtForestObjectDriver. More...
 
virtual bool exportTerrainAndProps (const std::string &)
 Saves terrain geometry and props to specified file. More...
 

Public Attributes

boost::signals2::signal< void(const
makArchives::DtTerrainRecord &)> 
signal_terrainRecordSet
 Signal sent. More...
 
boost::signals2::signal< void()> signal_navigationAreasCleared
 
boost::signals2::signal< void(const
DtFilename &)> 
signal_simTerrainLoaded
 Signal sent when a sim terrain is loaded. More...
 

Protected Member Functions

virtual void setNavigationAreasFromTerrainRecord (const makArchives::DtTerrainRecord &r, makArchives::DtTerrainRecord::GenericRecords &genericRecords, makArchives::DtTerrainRecord::GenericRecords &navigationAreas)
 
virtual void setGenericRecords (makArchives::DtTerrainRecord &rec, const makArchives::DtTerrainRecord::GenericRecords &, const makArchives::DtTerrainRecord::GenericRecords &navigationAreas) const
 Sets the generic records into the terrain records. More...
 
- Protected Member Functions inherited from makVrv::DtTerrain
void executeTerrainOperation (const makArchives::DtTerrainOperationRecord &operation, const makArchives::DtTerrainRecord &terrainRec)
 Execute a terrain operation. For example, adding a terrain patch. More...
 
void addTerrainOperationRecord (const makArchives::DtTerrainOperationRecord &operation)
 Add a terrain operations record and emit signal_terrainOperationAdded. More...
 
void removeTerrainOperationRecord (const makArchives::DtTerrainOperationRecord &operation)
 Remove a previously added record. More...
 
void removeTerrainOperationRecord (int id)
 Removed a terrain operations record and emit signal_terrainOperationAdded. More...
 
void clearTerrainOperations ()
 Remove all terrain operations from myTerrainOperationsMap emitting signals. More...
 
void slot_handleIsDayChanged (bool isDay)
 Turn on and off the lights when the sky object says to. More...
 
virtual bool checkIfTerrainOperationRecordsMatch (const makArchives::DtTerrainOperationRecord &left, const makArchives::DtTerrainOperationRecord &right)
 Check if two DtTerrainOperationRecord match without comparing the application type field. More...
 
virtual void connectForestAndOceanSignals (void)
 

Protected Attributes

makArchives::DtTerrainRecord::GenericRecords myGuiNavigationAreas
 
makArchives::DtTerrainRecord::GenericRecords mySimNavigationAreas
 
makArchives::DtTerrainRecord::GenericRecords myGenericGuiRecords
 
makArchives::DtTerrainRecord::GenericRecords myGenericSimRecords
 
makArchives::DtTerrainRecord mySimulationTerrainRecord
 
DtFilename mySimulationTerrain
 
bool myNavigationAreasAreOnSimulationTerrain
 
bool myNavigationAreasModified
 
makVrv::DtCoordinateSystemmySimulationNavigationCoordinateSystem
 
bool mySignalNewNavigationAreas
 
makVrv::DtSignalConnectionManager myConnections
 
- Protected Attributes inherited from makVrv::DtTerrain
DtDemyDe
 
DtTerrainSignalermySignaler
 
DtAgentManagerInterfacemyAgentManagerInterface
 
TerrainPatches myTerrainPatches
 
FeatureLayers myFeatureLayers
 
OceanLayers myOceanLayers
 
DtForestmyForest
 
DtBuoyBeaconLayermyBuoyLayer
 
DtStreamedFeatureLayermyStreamedFeatureLayer
 
DtDynamicFeatureLayermyDynamicFeatureLayer
 
DtNavigationLightManagermyNavigationLightManager
 
DtNavigationFeatureManagermyNavigationDaymarkManager
 
DtNavigationFeatureManagermyNavigationTopmarkManager
 
TerrainOperationsMap myTerrainOperationsMap
 
int myNextTerrainOperationId
 
bool myGlobalScaleFlag
 
PropNameMap myPropNameMap
 
makArchives::DtTerrainRecord::OptionalParameterMap myOptionalParameters
 
makArchives::DtTerrainRecord::GenericRecords myGenericRecords
 
std::string myDescription
 
bool myUseICO
 
unsigned int myMaxPagedLODs
 
bool myReloadingTerrain
 
DtTexturedQuadmyLogo
 

Additional Inherited Members

- Public Types inherited from makVrv::DtTerrain
typedef std::list
< DtTerrainPatch * > 
TerrainPatches
 
typedef std::list
< DtFeatureLayer * > 
FeatureLayers
 
typedef std::list< DtOceanLayer * > OceanLayers
 
typedef std::map< int,
makArchives::DtTerrainOperationRecord
TerrainOperationsMap
 Map of terrain operation ids, to terrain operations. More...
 
- Protected Types inherited from makVrv::DtTerrain
typedef std::map< std::string,
int
PropNameMap
 

Detailed Description

Extension of DtVrvTerrain that sends a signal when the terrain is set from record.

Constructor & Destructor Documentation

makVrf::DtVrfTerrain::DtVrfTerrain ( makVrv::DtDe de,
makVrv::DtAgentManagerInterface sceneManagerInterface 
)

CTOR.

virtual makVrf::DtVrfTerrain::~DtVrfTerrain ( )
virtual

DTOR.

Member Function Documentation

virtual void makVrf::DtVrfTerrain::setFromRecord ( const makArchives::DtTerrainRecord rec,
bool  clearFirst 
)
virtual

Populate a DtTerrain from a DtTerrainRecord.

Called by loadTerrain(). If the clearFirst flag is true, DtTerrain::clear() will be called before populating the new terrain

Reimplemented from makVrv::DtTerrain.

virtual const makArchives::DtTerrainRecord::GenericRecords& makVrf::DtVrfTerrain::navigationAreas ( ) const
virtual
virtual void makVrf::DtVrfTerrain::removeNavigationArea ( const std::string &  )
virtual
virtual void makVrf::DtVrfTerrain::addNavigationArea ( const std::string &  area)
virtual
virtual void makVrf::DtVrfTerrain::addNavigationArea ( const makArchives::DtGenericTerrainRecord record)
virtual
virtual void makVrf::DtVrfTerrain::changeNavigationAreaPath ( const std::string &  from,
const std::string &  to 
)
virtual
virtual bool makVrf::DtVrfTerrain::hasNavigationArea ( const DtFilename &  ) const
virtual
bool makVrf::DtVrfTerrain::navigationAreasModified ( ) const
inline
virtual void makVrf::DtVrfTerrain::clearNavigationAreasModified ( )
inlinevirtual
virtual void makVrf::DtVrfTerrain::clearNavigationAreas ( )
virtual
virtual void makVrf::DtVrfTerrain::getRecord ( makArchives::DtTerrainRecord rec)
virtual

Fill out a DtTerrainRecord with the current terrain info. Called by saveTerrain().

Reimplemented from makVrv::DtTerrain.

virtual makVrv::DtFeatureLayer* makVrf::DtVrfTerrain::findFeatureLayerNoPath ( const std::string &  featureLayerFilename)
virtual

Strips the path off the feature layers to see if the given name matches.

virtual const DtFilename& makVrf::DtVrfTerrain::simulationTerrain ( ) const
inlinevirtual
virtual bool makVrf::DtVrfTerrain::navigationAreasAreOnSimulationTerrain ( ) const
inlinevirtual
virtual std::string makVrf::DtVrfTerrain::navigationAreaTerrainFilename ( ) const
virtual

Returns the filename of the terrain to use for navigation area generation.

virtual void makVrf::DtVrfTerrain::getSimulationTerrainRecord ( makArchives::DtTerrainRecord ) const
virtual
virtual bool makVrf::DtVrfTerrain::loadSimulationTerrain ( const DtFilename &  )
virtual

Loads the simulation terrain given by the filename.

Returns false if terrain is not loaded. If terrain is loaded will signal that the terrain record has been set such that items that want to know about navigation areas can. Will clear existing navigation areas first

virtual void makVrf::DtVrfTerrain::clearSimTerrain ( )
virtual

Clears simulation terrain only. If the simulation terrain flag is not set then message will not be sent out for clearing navigation areas.

virtual void makVrf::DtVrfTerrain::clearGuiTerrain ( )
virtual

Clears the gui terrain. If there is no sim terrain loaded will also signal navigation areas cleared.

virtual void makVrf::DtVrfTerrain::setSignalNewNavigationAreas ( bool  )
virtual

When loading a terrain, whether or not to signal that the navigation areas are updated.

The clear will always be sent, but, this if for whether or not new navigation areas should be notified to the system. Call signalNavigationAreasUpdated to complete the process if this flag is set to false, and, then after load, reset

bool makVrf::DtVrfTerrain::signalNewNavigationAreas ( ) const
inline
virtual makVrv::DtCoordinateSystem& makVrf::DtVrfTerrain::navigationAreasCoordinateSystem ( ) const
virtual

Returns the coordinate system used by the navigation area.

virtual void makVrf::DtVrfTerrain::signalNavigationAreasUpdated ( )
virtual

Call to signal out navigation areas set signal.

virtual void makVrf::DtVrfTerrain::setNavigationAreasFromTerrainRecord ( const makArchives::DtTerrainRecord r,
makArchives::DtTerrainRecord::GenericRecords genericRecords,
makArchives::DtTerrainRecord::GenericRecords navigationAreas 
)
protectedvirtual
virtual void makVrf::DtVrfTerrain::setGenericRecords ( makArchives::DtTerrainRecord rec,
const makArchives::DtTerrainRecord::GenericRecords ,
const makArchives::DtTerrainRecord::GenericRecords navigationAreas 
) const
protectedvirtual

Sets the generic records into the terrain records.

If forGui is true, will only set the navigation area if the terrain does not have a simulation terrain loaded

Member Data Documentation

boost::signals2::signal<void (const makArchives::DtTerrainRecord&)> makVrf::DtVrfTerrain::signal_terrainRecordSet

Signal sent.

boost::signals2::signal<void ()> makVrf::DtVrfTerrain::signal_navigationAreasCleared
boost::signals2::signal<void (const DtFilename&)> makVrf::DtVrfTerrain::signal_simTerrainLoaded

Signal sent when a sim terrain is loaded.

makArchives::DtTerrainRecord::GenericRecords makVrf::DtVrfTerrain::myGuiNavigationAreas
protected
makArchives::DtTerrainRecord::GenericRecords makVrf::DtVrfTerrain::mySimNavigationAreas
protected
makArchives::DtTerrainRecord::GenericRecords makVrf::DtVrfTerrain::myGenericGuiRecords
protected
makArchives::DtTerrainRecord::GenericRecords makVrf::DtVrfTerrain::myGenericSimRecords
protected
makArchives::DtTerrainRecord makVrf::DtVrfTerrain::mySimulationTerrainRecord
protected
DtFilename makVrf::DtVrfTerrain::mySimulationTerrain
protected
bool makVrf::DtVrfTerrain::myNavigationAreasAreOnSimulationTerrain
protected
bool makVrf::DtVrfTerrain::myNavigationAreasModified
protected
makVrv::DtCoordinateSystem* makVrf::DtVrfTerrain::mySimulationNavigationCoordinateSystem
protected
bool makVrf::DtVrfTerrain::mySignalNewNavigationAreas
protected
makVrv::DtSignalConnectionManager makVrf::DtVrfTerrain::myConnections
protected

The documentation for this class was generated from the following file:

Document ID: Generated on Thu Aug 27 10:56:05 EDT 2020 from SVN revision 217100
Copyright © 2005-2020 MAK Technologies. All Rights Reserved (www.mak.com)