swift
simulatorfscommon.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (C) 2013 swift Project Community / Contributors
2 // SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3 
5 
6 #ifndef SWIFT_SIMPLUGIN_FSCOMMON_SIMULATORFSCOMMON_H
7 #define SWIFT_SIMPLUGIN_FSCOMMON_SIMULATORFSCOMMON_H
8 
9 #include <memory>
10 
11 #include <QObject>
12 
17 
18 namespace swift::simplugin::fscommon
19 {
22  {
23  Q_OBJECT
24  Q_INTERFACES(swift::core::ISimulator)
27 
28  public:
30  virtual ~CSimulatorFsCommon() override;
31 
32  // ---------------------- ISimulator ------------------
33  virtual bool disconnectFrom() override;
34  virtual bool isPaused() const override { return m_simPaused; }
35  // ---------------------- ISimulator ------------------
36 
37  protected:
41  swift::misc::simulation::IRemoteAircraftProvider *renderedAircraftProvider,
42  swift::misc::network::IClientProvider *clientProvider, QObject *parent = nullptr);
43 
45  virtual void initSimulatorInternals() override;
46 
48  virtual void reset() override;
49 
51  static void registerHelp();
52 
53  int m_ownAircraftUpdateCycles =
54  0;
55  int m_skipCockpitUpdateCycles = 0;
56  bool m_simPaused = false;
57 
58  // cockpit as set in SIM
63  };
64 } // namespace swift::simplugin::fscommon
65 
66 #endif // SWIFT_SIMPLUGIN_FSCOMMON_SIMULATORFSCOMMON_H
Interface to a simulator.
Definition: simulator.h:59
COM system (aka "radio")
Definition: comsystem.h:37
Value object for SELCAL.
Definition: selcal.h:31
Direct in memory access to client (network client) data.
Direct in memory access to interpolation setup, normally implemented by simulator.
Direct threadsafe in memory access to own aircraft.
Direct thread safe in memory access to remote aircraft.
Common base class for simulator plugins.
Common base class for MS flight simulators.
virtual bool isPaused() const
Simulator paused?
swift::misc::aviation::CComSystem m_simCom1
cockpit COM1 state in simulator
swift::misc::aviation::CSelcal m_selcal
SELCAL as in cockpit.
swift::misc::aviation::CComSystem m_simCom2
cockpit COM2 state in simulator
swift::misc::aviation::CTransponder m_simTransponder
cockpit xpdr state in simulator
#define FSCOMMON_EXPORT
FSCommon Export Macro.