XPMP2
X-Plane multiplayer library 2 - using instancing
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
XPMP2::RemoteAcPosUpdateTy Struct Reference

A/C Position updates based on global coordinates. More...

#include <XPMPRemote.h>

Public Member Functions

 RemoteAcPosUpdateTy ()
 Default Constructor sets all 0. More...
 
 RemoteAcPosUpdateTy (XPMPPlaneID _modeS_id, std::int16_t _dLat, std::int16_t _dLon, std::int16_t _dAlt_ft, std::uint16_t _dTime, float _pitch, float _heading, float _roll)
 Constructor sets all values. More...
 
void SetPitch (float _p)
 sets pitch from float More...
 
float GetPitch () const
 returns float pitch More...
 
void SetHeading (float _h)
 Sets heading from float. More...
 
float GetHeading () const
 returns float heading More...
 
void SetRoll (float _r)
 sets pitch from float More...
 
float GetRoll () const
 returns float pitch More...
 

Static Public Member Functions

static constexpr size_t msgSize ()
 message size More...
 

Public Attributes

std::uint32_t modeS_id
 plane's unique id at the sender side (might differ remotely in case of duplicates) More...
 
std::int16_t dLat
 [0.0000001 degrees] latitude position difference More...
 
std::int16_t dLon
 [0.0000001 degrees] longitude position difference More...
 
std::int16_t dAlt_ft
 [0.01 ft] altitude difference More...
 
std::uint16_t dTime
 [0.0001s] time difference to previous position in 1/10000s More...
 
std::int16_t pitch
 [0.01 degree] pitch/100 More...
 
std::uint16_t heading
 [0.01 degree] heading/100 More...
 
std::int16_t roll
 [0.01 degree] roll/100 More...
 
std::uint16_t filler1
 not yet used (for 4-byte alignment) More...
 

Detailed Description

A/C Position updates based on global coordinates.

for space efficiency only deltas to last msg are given in 0.0000001 degree lat/lon (roughly 1 centimeter resolution) and 0.01 ft altitude

Constructor & Destructor Documentation

◆ RemoteAcPosUpdateTy() [1/2]

XPMP2::RemoteAcPosUpdateTy::RemoteAcPosUpdateTy ( )
inline

Default Constructor sets all 0.

◆ RemoteAcPosUpdateTy() [2/2]

XPMP2::RemoteAcPosUpdateTy::RemoteAcPosUpdateTy ( XPMPPlaneID  _modeS_id,
std::int16_t  _dLat,
std::int16_t  _dLon,
std::int16_t  _dAlt_ft,
std::uint16_t  _dTime,
float  _pitch,
float  _heading,
float  _roll 
)

Constructor sets all values.

Member Function Documentation

◆ GetHeading()

float XPMP2::RemoteAcPosUpdateTy::GetHeading ( ) const
inline

returns float heading

◆ GetPitch()

float XPMP2::RemoteAcPosUpdateTy::GetPitch ( ) const
inline

returns float pitch

◆ GetRoll()

float XPMP2::RemoteAcPosUpdateTy::GetRoll ( ) const
inline

returns float pitch

◆ msgSize()

static constexpr size_t XPMP2::RemoteAcPosUpdateTy::msgSize ( )
inlinestaticconstexpr

message size

◆ SetHeading()

void XPMP2::RemoteAcPosUpdateTy::SetHeading ( float  _h)

Sets heading from float.

Note
Only works well for 0 <= _h < 360

◆ SetPitch()

void XPMP2::RemoteAcPosUpdateTy::SetPitch ( float  _p)
inline

sets pitch from float

◆ SetRoll()

void XPMP2::RemoteAcPosUpdateTy::SetRoll ( float  _r)
inline

sets pitch from float

Member Data Documentation

◆ dAlt_ft

std::int16_t XPMP2::RemoteAcPosUpdateTy::dAlt_ft

[0.01 ft] altitude difference

◆ dLat

std::int16_t XPMP2::RemoteAcPosUpdateTy::dLat

[0.0000001 degrees] latitude position difference

◆ dLon

std::int16_t XPMP2::RemoteAcPosUpdateTy::dLon

[0.0000001 degrees] longitude position difference

◆ dTime

std::uint16_t XPMP2::RemoteAcPosUpdateTy::dTime

[0.0001s] time difference to previous position in 1/10000s

◆ filler1

std::uint16_t XPMP2::RemoteAcPosUpdateTy::filler1

not yet used (for 4-byte alignment)

◆ heading

std::uint16_t XPMP2::RemoteAcPosUpdateTy::heading

[0.01 degree] heading/100

◆ modeS_id

std::uint32_t XPMP2::RemoteAcPosUpdateTy::modeS_id

plane's unique id at the sender side (might differ remotely in case of duplicates)

◆ pitch

std::int16_t XPMP2::RemoteAcPosUpdateTy::pitch

[0.01 degree] pitch/100

◆ roll

std::int16_t XPMP2::RemoteAcPosUpdateTy::roll

[0.01 degree] roll/100


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