Qt Virtual Chart Table (QVCT)
CInstrumentGAArtificialHorizon Class Reference

General aviation artificial horizon / AH (instrument) More...

#include <overlays/vessel/widgets/instruments/CInstrumentGAArtificialHorizon.hpp>

Inheritance diagram for CInstrumentGAArtificialHorizon:
CInstrument

Public Member Functions

 CInstrumentGAArtificialHorizon (CVesselCockpit *_poVesselCockpit)
 
virtual ~CInstrumentGAArtificialHorizon ()
 

Private Member Functions

virtual void draw ()
 Draws the instrument (resets if the vessel is undefined) More...
 
void drawStatic ()
 
void drawDynamic (const CVesselPoint *_poVesselPoint, double _fdPitch, double _fdRoll)
 

Private Attributes

QPixmap qPixmapBufferBackground
 Pixmap buffer used to render and cache the instrument's (static) background. More...
 
QPixmap qPixmapBufferForeground
 Pixmap buffer used to render and cache the instrument's (static) foreground. More...
 
QPixmap qPixmapBuffer
 Pixmap buffer used to render and cache the instrument. More...
 
bool bForceRedraw
 Forces the redraw of the instrument (not matter its cache content) More...
 
double fdPitch
 Pitch (angle) at which the last rendering was achieved. More...
 
double fdRoll
 Roll (angle) at which the last rendering was achieved. More...
 
double fdBearing
 Bearing at which the last rendering was achieved. More...
 
double fdTime
 Time at which the last rendering was achieved. More...
 

Additional Inherited Members

- Protected Member Functions inherited from CInstrument
 CInstrument (CVesselCockpit *_poVesselCockpit)
 
virtual ~CInstrument ()
 
virtual void paintEvent (QPaintEvent *_pqPaintEvent)
 
CVesselPoint * useVesselPoint ()
 Returns parent cockpit's associated vessel (0 if the vessel is undefined) More...
 

Detailed Description

General aviation artificial horizon / AH (instrument)

This class allows to draw a general aviation (analogic) artificial horizon (AH). The pitch and roll angles are artificially computed based on the vertical vs. horizontal speeds (pitch) and the rate of turn vs. horizontal speed (roll). It includes the logic that allows to cache the necessary QPixmap(s) required to draw the instrument and avoid to "re-render" it each time it is "refreshed".

Author
Cedric Dufour http://cedric.dufour.name

Definition at line 43 of file CInstrumentGAArtificialHorizon.hpp.

Constructor & Destructor Documentation

◆ CInstrumentGAArtificialHorizon()

CInstrumentGAArtificialHorizon::CInstrumentGAArtificialHorizon ( CVesselCockpit *  _poVesselCockpit)

Definition at line 44 of file CInstrumentGAArtificialHorizon.cpp.

◆ ~CInstrumentGAArtificialHorizon()

virtual CInstrumentGAArtificialHorizon::~CInstrumentGAArtificialHorizon ( )
inlinevirtual

Definition at line 75 of file CInstrumentGAArtificialHorizon.hpp.

Member Function Documentation

◆ draw()

void CInstrumentGAArtificialHorizon::draw ( )
privatevirtual

Draws the instrument (resets if the vessel is undefined)

Implements CInstrument.

Definition at line 59 of file CInstrumentGAArtificialHorizon.cpp.

◆ drawStatic()

void CInstrumentGAArtificialHorizon::drawStatic ( )
private

Definition at line 134 of file CInstrumentGAArtificialHorizon.cpp.

◆ drawDynamic()

void CInstrumentGAArtificialHorizon::drawDynamic ( const CVesselPoint *  _poVesselPoint,
double  _fdPitch,
double  _fdRoll 
)
private

Definition at line 282 of file CInstrumentGAArtificialHorizon.cpp.

Member Data Documentation

◆ qPixmapBufferBackground

QPixmap CInstrumentGAArtificialHorizon::qPixmapBufferBackground
private

Pixmap buffer used to render and cache the instrument's (static) background.

Definition at line 51 of file CInstrumentGAArtificialHorizon.hpp.

◆ qPixmapBufferForeground

QPixmap CInstrumentGAArtificialHorizon::qPixmapBufferForeground
private

Pixmap buffer used to render and cache the instrument's (static) foreground.

Definition at line 53 of file CInstrumentGAArtificialHorizon.hpp.

◆ qPixmapBuffer

QPixmap CInstrumentGAArtificialHorizon::qPixmapBuffer
private

Pixmap buffer used to render and cache the instrument.

Definition at line 55 of file CInstrumentGAArtificialHorizon.hpp.

◆ bForceRedraw

bool CInstrumentGAArtificialHorizon::bForceRedraw
private

Forces the redraw of the instrument (not matter its cache content)

Definition at line 58 of file CInstrumentGAArtificialHorizon.hpp.

◆ fdPitch

double CInstrumentGAArtificialHorizon::fdPitch
private

Pitch (angle) at which the last rendering was achieved.

Definition at line 60 of file CInstrumentGAArtificialHorizon.hpp.

◆ fdRoll

double CInstrumentGAArtificialHorizon::fdRoll
private

Roll (angle) at which the last rendering was achieved.

Definition at line 62 of file CInstrumentGAArtificialHorizon.hpp.

◆ fdBearing

double CInstrumentGAArtificialHorizon::fdBearing
private

Bearing at which the last rendering was achieved.

Definition at line 64 of file CInstrumentGAArtificialHorizon.hpp.

◆ fdTime

double CInstrumentGAArtificialHorizon::fdTime
private

Time at which the last rendering was achieved.

Definition at line 66 of file CInstrumentGAArtificialHorizon.hpp.


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