|
swift
|
Class representing a SimConnect object. More...
Public Types | |
| enum | SimObjectType { AircraftNonAtc , AircraftSimulatedObject , TerrainProbe , AllTypes } |
| Type. | |
Public Member Functions | |
| CSimConnectObject () | |
| Constructor. | |
| CSimConnectObject (SimObjectType type) | |
| Constructor. | |
| CSimConnectObject (const swift::misc::simulation::CSimulatedAircraft &aircraft, DWORD requestId, swift::misc::simulation::ISimulationEnvironmentProvider *simEnvProvider, swift::misc::simulation::IInterpolationSetupProvider *setupProvider, swift::misc::simulation::IRemoteAircraftProvider *remoteAircraftProvider, swift::misc::simulation::CInterpolationLogger *logger) | |
| Constructor providing initial situation/parts. | |
| const swift::misc::aviation::CCallsign & | getCallsign () const |
| Get callsign. | |
| const QString & | getCallsignAsString () const |
| Get callsign. | |
| bool | hasCallsign () const |
| Callsign? | |
| const swift::misc::simulation::CSimulatedAircraft & | getAircraft () const |
| Simulated aircraft (as added) | |
| const swift::misc::simulation::CAircraftModel & | getAircraftModel () const |
| Simulated aircraft model. | |
| const QString & | getAircraftModelString () const |
| Simulated aircraft model string. | |
| SimObjectType | getType () const |
| Object type. | |
| const QString & | getTypeAsString () const |
| Type as string. | |
| bool | isAircraft () const |
| Aircraft? | |
| bool | isAircraftSimulatedObject () const |
| Aircraft simulated object? | |
| bool | isAircraftNonAtc () const |
| Aircraft NON ATC? | |
| bool | isTerrainProbe () const |
| Probe? | |
| void | setType (SimObjectType type) |
| Set the type. | |
| void | setAircraft (const swift::misc::simulation::CSimulatedAircraft &aircraft) |
| Set the aircraft. | |
| void | setAircraftModelString (const QString &modelString) |
| Set model string. | |
| void | setAircraftCG (const swift::misc::physical_quantities::CLength &cg) |
| Set CG. | |
| const swift::misc::aviation::CAircraftLights & | getCurrentLightsInSimulator () const |
| Get current lights (requested from simulator) | |
| bool | hasCurrentLightsInSimulator () const |
| Received lights in simulator. | |
| void | setCurrentLightsInSimulator (const swift::misc::aviation::CAircraftLights &lights) |
| Set current lights when received from simulator. | |
| void | fakeCurrentLightsInSimulator () |
| Pretend to have received lights from simulator. | |
| const swift::misc::aviation::CAircraftLights & | getLightsAsSent () const |
| Lights as sent to simulator. | |
| void | setLightsAsSent (const swift::misc::aviation::CAircraftLights &lights) |
| Lights as sent to simulator. | |
| SIMCONNECT_PERIOD | getSimDataPeriod () const |
| How often do we request data from simulator for this remote aircraft. | |
| void | setSimDataPeriod (SIMCONNECT_PERIOD period) |
| How often do we request data from simulator for this remote aircraft. | |
| void | setRequestId (DWORD id) |
| Set Simconnect request id. | |
| DWORD | getRequestId () const |
| Get SimConnect request id. | |
| DWORD | getRequestId (CSimConnectDefinitions::SimObjectRequest offset) const |
| Get SimConnect with offset. | |
| void | setObjectId (DWORD id) |
| Set Simconnect object id. | |
| DWORD | getObjectId () const |
| Get SimConnect object id. | |
| QString | getObjectIdAsString () const |
| Get SimConnect object id. | |
| bool | hasValidRequestId () const |
| Valid request id? | |
| bool | hasValidObjectId () const |
| Valid object id? | |
| bool | isPendingAdded () const |
| Object is requested in simulator, not yet confirmed added. | |
| bool | isOutdatedPendingAdded (qint64 thresholdMs=5000, qint64 currentMsSinceEpoch=-1) const |
| Still pending. | |
| bool | isConfirmedAdded () const |
| Adding is confirmed. | |
| void | setConfirmedAdded (bool confirm) |
| Marked as confirmed, means the simulator has "confirmed" the objectId as added and not instantly removed the object. | |
| bool | isPendingRemoved () const |
| Removing is pending. | |
| bool | isReadyToSend () const |
| Object which can be used for sending, not pending and valid ids. | |
| void | setPendingRemoved (bool pending) |
| Marked as pending for removal. | |
| bool | isPending () const |
| Pending added or removed? | |
| bool | hasCamera () const |
| Has camera? | |
| void | resetCameraPositions () |
| Reset camera positions. | |
| const SIMCONNECT_DATA_XYZ & | cameraPosition () const |
| Camera position. | |
| const SIMCONNECT_DATA_PBH & | cameraRotation () const |
| Camera rotation;. | |
| void | setCameraPositionAndRotation (const SIMCONNECT_DATA_XYZ &position, const SIMCONNECT_DATA_PBH &rotation) |
| Camera position/rotation. | |
| GUID | getCameraGUID () const |
| Camera GUID. | |
| void | setCameraGUID (GUID guid) |
| Set camera GUID. | |
| void | removeCamera () |
| No camera anymore. | |
| void | setObserverName (const QString &observer) |
| Set observer. | |
| const QString & | getObserverName () const |
| Observer name. | |
| void | resetState () |
| Reset the state (like it was a new onject) without affecting interpolator and aircraft. | |
| void | resetToAddAgain () |
| Reset so it can be added again. | |
| void | resetTimestampToNow () |
| Reset the timestamp. | |
| bool | isVtol () const |
| VTOL? | |
| bool | isValid () const |
| Valid? | |
| bool | isInvalid () const |
| Invalid? | |
| bool | hasCreatedTimestamp () const |
| Created timestamp? | |
| qint64 | getCreatedTimestamp () const |
| Created timestamp. | |
| int | getEngineCount () const |
| Engine count. | |
| bool | hasValidRequestAndObjectId () const |
| Was the object really added to simulator. | |
| int | getAddingExceptions () const |
| Adding has been failed before. | |
| void | setAddingExceptions (int number) |
| Set adding failed before. | |
| void | increaseAddingExceptions () |
| Increase adding exception. | |
| void | decreaseAddingExceptions () |
| Decrease adding exception. | |
| int | getAddingDirectlyRemoved () const |
| Adding and directly removed. | |
| void | setAddingDirectlyRemoved (int number) |
| Set adding and directly removed. | |
| void | increaseAddingDirectlyRemoved () |
| Increase adding and directly removed. | |
| void | copyAddingFailureCounters (const CSimConnectObject &otherObject) |
| Copy the counters from another object. | |
| const QByteArray & | getCallsignByteArray () const |
| Callsign as LATIN1. | |
| QString | getInterpolatorInfo (swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode mode) const |
| Get an interpolator info string (for debug info) More... | |
| void | attachInterpolatorLogger (swift::misc::simulation::CInterpolationLogger *logger) const |
| Attach an observer to read the interpolator's state for debugging. More... | |
| swift::misc::simulation::CInterpolationResult | getInterpolation (qint64 currentTimeSinceEpoch, const swift::misc::simulation::CInterpolationAndRenderingSetupPerCallsign &setup, uint32_t aircraftNumber) const |
| Get interpolated situation. More... | |
| const swift::misc::aviation::CAircraftSituation & | getLastInterpolatedSituation (swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode mode) const |
| Latest interpolation result. More... | |
| const swift::misc::CStatusMessageList & | getInterpolationMessages (swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode mode) const |
| Interpolation messages. More... | |
| swift::misc::simulation::CInterpolatorMulti * | getInterpolator () const |
| Interpolator. | |
| QString | toQString () const |
| SimObject as string. | |
| bool | isAddedWhileRemoving () |
| Special states. | |
| void | setAddedWhileRemoving (bool addedWileRemoved) |
| Special states. | |
| bool | isRemovedWhileAdding () const |
| Special states. | |
| void | setRemovedWhileAdding (bool removedWhileAdding) |
| Special states. | |
Static Public Member Functions | |
| static SimObjectType | requestIdToType (DWORD requestId) |
| Type of id. | |
| static const QString & | typeToString (SimObjectType type) |
| Type to string. | |
| static bool | isSameTypeGroup (SimObjectType t1, SimObjectType t2) |
| Same type. | |
| static bool | isAircraft (SimObjectType type) |
| Aircraft? | |
Class representing a SimConnect object.
Definition at line 21 of file simconnectobject.h.
| void swift::simplugin::fsxcommon::CSimConnectObject::attachInterpolatorLogger | ( | swift::misc::simulation::CInterpolationLogger * | logger | ) | const |
Attach an observer to read the interpolator's state for debugging.
bool log flag Definition at line 192 of file simconnectobject.cpp.
| CInterpolationResult swift::simplugin::fsxcommon::CSimConnectObject::getInterpolation | ( | qint64 | currentTimeSinceEpoch, |
| const swift::misc::simulation::CInterpolationAndRenderingSetupPerCallsign & | setup, | ||
| uint32_t | aircraftNumber | ||
| ) | const |
Get interpolated situation.
| currentTimeSinceEpoch | milliseconds since epoch for which the situation should be interpolated |
| setup | interpolation setup |
| aircraftNumber | number used to spread the computational load of part interpolation |
Definition at line 198 of file simconnectobject.cpp.
| const CStatusMessageList & swift::simplugin::fsxcommon::CSimConnectObject::getInterpolationMessages | ( | swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode | mode | ) | const |
Interpolation messages.
Definition at line 214 of file simconnectobject.cpp.
| QString swift::simplugin::fsxcommon::CSimConnectObject::getInterpolatorInfo | ( | swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode | mode | ) | const |
Get an interpolator info string (for debug info)
Definition at line 186 of file simconnectobject.cpp.
| const CAircraftSituation & swift::simplugin::fsxcommon::CSimConnectObject::getLastInterpolatedSituation | ( | swift::misc::simulation::CInterpolationAndRenderingSetupBase::InterpolatorMode | mode | ) | const |
Latest interpolation result.
Definition at line 207 of file simconnectobject.cpp.