VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Classes | Public Types | Public Member Functions | Private Member Functions
DtAdsbDataServiceInterface Class Referenceabstract

Abstract interface class to the ADSB data service. This service provides access to Automatic Dependent Surveillance - Broadcast (ADS-B) data, which is used to track and monitor real world aircraft. This data can be used to create and simulate clutter entities in a simulation.

Inheritance diagram for DtAdsbDataServiceInterface:
Inheritance graph
[legend]

Classes

class  DtAdsbDataJob
 

Public Types

using DtIcaoAddress = int
 
using DtIcaoAddrSet = std::set< DtIcaoAddress >
 

Public Member Functions

 DtAdsbDataServiceInterface ()
 
virtual ~DtAdsbDataServiceInterface ()
 
virtual bool isDataLoading () const =0
 
virtual bool isFileLoadError () const =0
 
virtual DtAdsbDataJob::Ptr findTracksInArea (const DtVertexList &areaVertices, bool unownedOnly=true)=0
 
virtual DtAdsbDataJob::Ptr findTracksInAreaDuringTime (const DtVertexList &areaVertices, double startSimTime, double endSimTime, bool unownedOnly)=0
 
virtual DtTrackHandlePtr trackHandleForAddress (DtIcaoAddress trackId) const =0
 
virtual DtAdsbDataJob::Ptr requestOwnershipOfTracks (const DtIcaoAddrSet &trackIds, const double lastSimTime)=0
 
virtual DtAdsbDataJob::Ptr releaseOwnershipOfTracks (const DtIcaoAddrSet &trackIds)=0
 
virtual double adsbTimeFromSimTime (double simTime) const =0
 
virtual std::string stringForEpochTime (double t) const =0
 
virtual double simTimeFromAdsbTime (double adsbTime) const =0
 
virtual double finalDataSimTime () const =0
 
virtual DtPointHandlePtr firstPointAfterTime (const DtTrackHandlePtr track, double simTime) const =0
 
virtual DtPointHandlePtr lastPointBeforeTime (const DtTrackHandlePtr track, double simTime) const =0
 
virtual DtPointHandlePtr clonePoint (const DtPointHandlePtr p) const =0
 
virtual void updateSquawkChangedTimestamp (const int icaoAddress, const double &simTime)=0
 
virtual double barometricAltitudeAdjustment (const DtVector &localPosition, const double simTime) const =0
 
virtual void resetData ()=0
 

Private Member Functions

 DtAdsbDataServiceInterface (const DtAdsbDataServiceInterface &)
 
DtAdsbDataServiceInterfaceoperator= (const DtAdsbDataServiceInterface &)
 

Member Typedef Documentation

Constructor & Destructor Documentation

DtAdsbDataServiceInterface::DtAdsbDataServiceInterface ( )
inline
virtual DtAdsbDataServiceInterface::~DtAdsbDataServiceInterface ( )
inlinevirtual
DtAdsbDataServiceInterface::DtAdsbDataServiceInterface ( const DtAdsbDataServiceInterface )
private

Copy constructor not implemented.

Member Function Documentation

virtual bool DtAdsbDataServiceInterface::isDataLoading ( ) const
pure virtual

Returns true if ADSB data is being loaded. Tracks should not be accessed when this is true. Track job ticks will do nothing while this is true.

Implemented in DtAdsbDataManager.

virtual bool DtAdsbDataServiceInterface::isFileLoadError ( ) const
pure virtual

Indicates that there was an error during the reading of data files, and the data manager cannot provide data.

Implemented in DtAdsbDataManager.

virtual DtAdsbDataJob::Ptr DtAdsbDataServiceInterface::findTracksInArea ( const DtVertexList areaVertices,
bool  unownedOnly = true 
)
pure virtual

Starts a query for all tracks in the specified area. The last point in a track before the current sim time must be in the area for the track to be considered in the area.
If unownedOnly is true (the default) then only unowned tracks are returned. areaVertices are in geocentric coordinates.

Implemented in DtAdsbDataManager.

virtual DtAdsbDataJob::Ptr DtAdsbDataServiceInterface::findTracksInAreaDuringTime ( const DtVertexList areaVertices,
double  startSimTime,
double  endSimTime,
bool  unownedOnly 
)
pure virtual

Starts a query for all tracks in the specified area. A track must cross the area between the given sim times for the track to be considered in the area. Note that if the startSimTime is before the current sim time, the Data Service may no longer have that path data available.
If unownedOnly is true (the default) then only unowned tracks are returned. areaVertices are in geocentric coordinates.

Implemented in DtAdsbDataManager.

virtual DtTrackHandlePtr DtAdsbDataServiceInterface::trackHandleForAddress ( DtIcaoAddress  trackId) const
pure virtual

Returns information for the track with the specified address, or an empty pointer if it could not be found. Will always return an empty pointer if there is a file load in progress or there was a load error. (The caller of this function should check that result.get() != nullPtr before using the result.)

Implemented in DtAdsbDataManager.

virtual DtAdsbDataJob::Ptr DtAdsbDataServiceInterface::requestOwnershipOfTracks ( const DtIcaoAddrSet trackIds,
const double  lastSimTime 
)
pure virtual

Request ownership of the specified given tracks.

Parameters
trackIdsis the set of track IDs that the requester would like to own.
lastSimTimeis the last time of interest for these tracks. This time is used to determine what data to read from files, if the data is not already in memory.

Implemented in DtAdsbDataManager.

virtual DtAdsbDataJob::Ptr DtAdsbDataServiceInterface::releaseOwnershipOfTracks ( const DtIcaoAddrSet trackIds)
pure virtual

Release ownership of the specified tracks.

Implemented in DtAdsbDataManager.

virtual double DtAdsbDataServiceInterface::adsbTimeFromSimTime ( double  simTime) const
pure virtual

Converts a sim time to ADSB data time. Needed to understand how sim time relates to the timestamps in the ADSB track data.

Implemented in DtAdsbDataManager.

virtual std::string DtAdsbDataServiceInterface::stringForEpochTime ( double  t) const
pure virtual

Provides a string for the "adsb time" in a path point time stamp. This is useful in finding points in the source ADSB data for debugging.

Implemented in DtAdsbDataManager.

virtual double DtAdsbDataServiceInterface::simTimeFromAdsbTime ( double  adsbTime) const
pure virtual

Converts the ADSB data time to sim time. Needed to understand how sim time relates to the timestamps in the ADSB track data.

Implemented in DtAdsbDataManager.

virtual double DtAdsbDataServiceInterface::finalDataSimTime ( ) const
pure virtual

Returns the sim time for the last point of ADSB data available.

Implemented in DtAdsbDataManager.

virtual DtPointHandlePtr DtAdsbDataServiceInterface::firstPointAfterTime ( const DtTrackHandlePtr  track,
double  simTime 
) const
pure virtual

Find the first point in the track's path that occurs after (or at) the specified sim time. If no points meet this criteria, an empty pointer is returned. (The caller of this function should check that result.get() != nullPtr before using the result.)

Implemented in DtAdsbDataManager.

virtual DtPointHandlePtr DtAdsbDataServiceInterface::lastPointBeforeTime ( const DtTrackHandlePtr  track,
double  simTime 
) const
pure virtual

Find the last point in the track's path that occurs before (or at) the specified sim time. If no points meet this criteria, an empty pointer is returned. (The caller of this function should check that result.get() != nullPtr before using the result.)

Implemented in DtAdsbDataManager.

virtual DtPointHandlePtr DtAdsbDataServiceInterface::clonePoint ( const DtPointHandlePtr  p) const
pure virtual

Makes a new point handle that refers to the same path point as p. The original or new handle can later be changed (e.g., with the ++ operator) without affecting the other handle.

Implemented in DtAdsbDataManager.

virtual void DtAdsbDataServiceInterface::updateSquawkChangedTimestamp ( const int  icaoAddress,
const double simTime 
)
pure virtual

Find the first point in the track's path that occurs after the specified sim time that contains a new squawk code and update the track's mySquawkChangedTimestamp value. If no points meet this criteria, the track's mySquawkChangedTimestamp value is set to infinity, indicating there is no new squawk code in the path points thus far.

Implemented in DtAdsbDataManager.

virtual double DtAdsbDataServiceInterface::barometricAltitudeAdjustment ( const DtVector &  localPosition,
const double  simTime 
) const
pure virtual

Returns barometric altitude adjustment. This is a distance in meters that is added to the pressure altitude data in ADSB to determine an altitude in the simulation. Ideally this function would use the measured sea level pressure at the (2D) location at the given time compared to the Standard Atmosphere to calculate the offset. The default function just returns a constant, however.

Implemented in DtAdsbDataManager.

virtual void DtAdsbDataServiceInterface::resetData ( )
pure virtual

Marks ADSB data to be reset. This is called in the cgf module when a scenario is rewound, rolled back, or closed.
Since as a scenario plays, ADSB data is incrementally deleted from memory, a scenario rewind in general requires that data files be re-read. Therefore this function clears and resets everything in the ADSB data manager so that it reads all files again.

Implemented in DtAdsbDataManager.

DtAdsbDataServiceInterface& DtAdsbDataServiceInterface::operator= ( const DtAdsbDataServiceInterface )
private

Assignment operator not implemented.


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

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)