6 #ifndef SWIFT_MISC_SIMULATION_INTERPOLATION_INTERPOLATOR_H
7 #define SWIFT_MISC_SIMULATION_INTERPOLATION_INTERPOLATOR_H
10 #include <QStringList>
31 namespace swift::misc::simulation
33 class CInterpolationLogger;
34 class CInterpolatorLinear;
35 class CInterpolatorSpline;
49 static const QStringList &getLogCategories();
61 uint32_t aircraftNumber);
71 QString getInterpolatorInfo()
const;
75 void resetLastInterpolation();
82 void markAsUnitTest();
103 bool doLogging()
const;
109 qint64 m_currentTimeMsSinceEpoch = -1;
110 qint64 m_lastInvalidLogTs = -1;
120 int m_partsToSituationInterpolationRatio =
122 int m_partsToSituationGuessingRatio = 5;
123 int m_invalidSituations = 0;
132 qint64 m_situationsLastModified { -1 };
133 qint64 m_situationsLastModifiedUsed { -1 };
134 int m_interpolatedSituationsCounter {
141 bool m_unitTest =
false;
148 bool initIniterpolationStepData(qint64 currentTimeSinceEpoch,
Status messages, e.g. from Core -> GUI.
Value object encapsulating information of aircraft's parts.
static const CAircraftParts & null()
NULL parts object.
Value object about changes in situations.
Value object encapsulating information of an aircraft's situation.
static const CAircraftSituation & null()
Null situation.
List of aircraft situations.
Value object encapsulating information of a callsign.
Physical unit length (length)
static const CLength & null()
NULL PQ.
Aircraft model (used by another pilot, my models on disk)
Value object for interpolator and rendering per callsign.
Record internal state of interpolator for debugging.
Class which can be directly used to access an.
Base class for interpolating (calculate positions inbetween updates). One instance is responsible for...
bool hasInterpolationMessages() const
Do we have interpolation messages.
const physical_quantities::CLength & getModelCG() const
Center of gravity.
CInterpolationStatus m_currentInterpolationStatus
this step's situation status
CInterpolationAndRenderingSetupPerCallsign m_currentSetup
used setup
CPartsStatus m_currentPartsStatus
this step's parts status
void attachLogger(CInterpolationLogger *logger)
Attach an observer to read the interpolator's state for debugging.
aviation::CAircraftSituationChange m_pastSituationsChange
situations change of provider (i.e.
CStatusMessageList m_interpolationMessages
interpolation messages
CPartsStatus m_lastPartsStatus
status for last parts, used when last parts are re-used because of m_partsToSituationInterpolationRat...
aviation::CAircraftSituationList m_currentSituations
current situations obtained by remoteAircraftSituationsAndChange
const aviation::CCallsign m_callsign
corresponding callsign
virtual const IInterpolant & getInterpolant(SituationLog &log)=0
Get the interpolant for the given time point.
const aviation::CAircraftSituation & getLastInterpolatedSituation() const
Latest interpolation result.
bool hasAttachedLogger() const
Is logger attached?
const CStatusMessageList & getInterpolationMessages() const
Interpolation messages.
CAircraftModel m_model
corresponding model (required for CG)
int getInvalidSituationsCount() const
Get count of invalid situations.
Class which can be directly used to access an.
Class which can be directly used to access an.
Direct in memory access to interpolation setup, normally implemented by simulator.
Direct thread safe in memory access to remote aircraft.
Direct in memory access to elevation data.
Log entry for situation interpolation.
#define SWIFT_MISC_EXPORT
Export a class or function from the library.