gramods
Namespaces | Functions | Variables
gramods Namespace Reference

Gramods, short for Graphics Modules, is a collection of weakly inter dependent and useful APIs for Virtual Reality and graphics cluster rendering. More...

Namespaces

 gmCore
 The gmCore module specifies utilities for loading other modules and configure them based on configuration files, for handling library and application error, warning and debugging output, and possibly also for initialization of third party libraries that may be used by other modules.
 
 gmGraphics
 The gmGraphics module provides nodes primarily for graphics rendering pipeline definition and handling.
 
 gmMisc
 The miscellaneous module (misc) contains functionality that cannot be categorized in a good way that would not result in one module for each class.
 
 gmNetwork
 The gmNetwork module provides network data synchronization and execution synchronization.
 
 gmSound
 The module provides sound handling functionality for the implementation of sound screen or sound table interaction.
 
 gmTouch
 The module provides touch handling functionality for the implementation of touch screen or touch table interaction.
 
 gmTrack
 The gmTrack module provides primarily pose tracking clients, servers and filters.
 

Functions

std::istream & operator>> (std::istream &in, gmCore::angle &v)
 Stream operator reading into a angle. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::angle2 &s)
 Stream operator reading two values into a angle2. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::angle3 &s)
 Stream operator reading three values into a angle3. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::angle4 &s)
 Stream operator reading four values into a angle4. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::angle2 &s)
 Stream operator writing two values from a angle2. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::angle3 &s)
 Stream operator writing three values from a angle3. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::angle4 &s)
 Stream operator writing four values from a angle4. More...
 
std::istream & operator>> (std::istream &in, Eigen::Vector2f &v)
 Stream operator reading two values into an Eigen::Vector2f. More...
 
std::istream & operator>> (std::istream &in, Eigen::Vector3f &v)
 Stream operator reading three values into an Eigen::Vector3f. More...
 
std::istream & operator>> (std::istream &in, Eigen::Quaternionf &q)
 Stream operator reading into an Eigen::Quaternionf. More...
 
std::istream & operator>> (std::istream &in, Eigen::Matrix3f &m)
 Stream operator reading nine values into an Eigen::Matrix3f. More...
 
std::istream & operator>> (std::istream &in, Eigen::Matrix4f &m)
 Stream operator reading 9, 12 or 16 values into an Eigen::Matrix4f. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::float2 &s)
 Stream operator reading two values into a float2. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::float3 &s)
 Stream operator reading three values into a float3. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::float4 &s)
 Stream operator reading four values into a float4. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::float12 &s)
 Stream operator reading 12 values into a float12. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::float2 &s)
 Stream operator writing two values from a float2. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::float3 &s)
 Stream operator writing three values from a float3. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::float4 &s)
 Stream operator writing four values from a float4. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::float12 &s)
 Stream operator writing 12 values from a float12. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::int2 &s)
 Stream operator reading two values into a int2. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::int3 &s)
 Stream operator reading three values into a int3. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::int4 &s)
 Stream operator reading four values into a int4. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::int2 &s)
 Stream operator writing two values from a int2. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::int3 &s)
 Stream operator writing three values from a int3. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::int4 &s)
 Stream operator writing four values from a int4. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::size2 &s)
 Stream operator reading two values into a size2. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::size3 &s)
 Stream operator reading three values into a size3. More...
 
std::istream & operator>> (std::istream &in, gramods::gmCore::size4 &s)
 Stream operator reading four values into a size4. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::size2 &s)
 Stream operator writing two values from a size2. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::size3 &s)
 Stream operator writing three values from a size3. More...
 
std::ostream & operator<< (std::ostream &out, gramods::gmCore::size4 &s)
 Stream operator writing four values from a size4. More...
 
std::ostream & operator<< (std::ostream &out, const std::type_info &id)
 Stream operator for writing type_info name to a stream. More...
 
std::istream & operator>> (std::istream &in, gmGraphics::Eye &e)
 Stream operator reading into an Eye. More...
 
const gmMisc::PolyFit SPEED_OF_SOUND ({{35}, {30}, {25}, {20}, {15}, {10}, {5}, {0}, {-5}, {-10}, {-15}, {-20}, {-25}}, {{351.88}, {349.02}, {346.13}, {343.21}, {340.27}, {337.31}, {334.32}, {331.30}, {328.25}, {325.18}, {322.07}, {318.94}, {315.77}}, 2)
 Second order approximation of the speed of sound in standard air, based on table at Wikipedia. More...
 

Variables

constexpr double GM_PI_4 = 0.78539816339744830961566084581987572104929234984378
 
constexpr double GM_PI_2 = 1.57079632679489661923132169163975144209858469968755
 
constexpr double GM_PI = 3.14159265358979323846264338327950288419716939937511
 
constexpr double GM_2_PI = 6.28318530717958647692528676655900576839433879875021
 
constexpr float SPEED_OF_SOUND_T20 = 343.f
 The speed of sound in standard air at 20°C. More...
 
constexpr float SPEED_OF_SOUND_T0 = 331.f
 The speed of sound in standard air at 0°C. More...
 

Detailed Description

Gramods, short for Graphics Modules, is a collection of weakly inter dependent and useful APIs for Virtual Reality and graphics cluster rendering.

(c)2023 Karljohan Lundin Palmerius

Copyright 2018, Karljohan Lundin Palmerius Copyright 2011, GManNickG @ stackoverflow.com.

Copyright 2003-2018, Karljohan Lundin Palmerius Copyright 2010, Loki Astari (http://stackoverflow.com)

The main purpose of the Gramods library is to simplify loading of platform dependent configurations into a pre-compiled application, while also simplifying the implementation of such applications. The aim is to be able to implement an application that employs execution and data synchronization over network and synchronized multi window rendering in a flexible and configurable way.

Function Documentation

◆ operator<<() [1/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
const std::type_info &  id 
)

Stream operator for writing type_info name to a stream.

This will demangle when necessary. Usage: out << typeid(*ptr);

◆ operator<<() [2/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::angle2 s 
)
inline

Stream operator writing two values from a angle2.

◆ operator<<() [3/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::angle3 s 
)
inline

Stream operator writing three values from a angle3.

◆ operator<<() [4/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::angle4 s 
)
inline

Stream operator writing four values from a angle4.

◆ operator<<() [5/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::float12 s 
)
inline

Stream operator writing 12 values from a float12.

◆ operator<<() [6/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::float2 s 
)
inline

Stream operator writing two values from a float2.

◆ operator<<() [7/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::float3 s 
)
inline

Stream operator writing three values from a float3.

◆ operator<<() [8/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::float4 s 
)
inline

Stream operator writing four values from a float4.

◆ operator<<() [9/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::int2 s 
)
inline

Stream operator writing two values from a int2.

◆ operator<<() [10/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::int3 s 
)
inline

Stream operator writing three values from a int3.

◆ operator<<() [11/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::int4 s 
)
inline

Stream operator writing four values from a int4.

◆ operator<<() [12/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::size2 s 
)
inline

Stream operator writing two values from a size2.

◆ operator<<() [13/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::size3 s 
)
inline

Stream operator writing three values from a size3.

◆ operator<<() [14/14]

std::ostream& gramods::operator<< ( std::ostream &  out,
gramods::gmCore::size4 s 
)
inline

Stream operator writing four values from a size4.

◆ operator>>() [1/20]

std::istream & gramods::operator>> ( std::istream &  in,
Eigen::Matrix3f &  m 
)

Stream operator reading nine values into an Eigen::Matrix3f.

This is typically used to read XML position and matrix attributes. This will read nine values from the stream.

◆ operator>>() [2/20]

std::istream & gramods::operator>> ( std::istream &  in,
Eigen::Matrix4f &  m 
)

Stream operator reading 9, 12 or 16 values into an Eigen::Matrix4f.

This is typically used to read XML position and matrix attributes. This will read 16 values from the stream.

◆ operator>>() [3/20]

std::istream & gramods::operator>> ( std::istream &  in,
Eigen::Quaternionf &  q 
)

Stream operator reading into an Eigen::Quaternionf.

This is typically used to read XML orientation and rotation attributes. Default behavior is to read four values (w x y z), but this behavior can be modified by prefixing with a keyword:

  • quaternion w x y z, e.g. "quaternion 1 0 0 0": Enforce the default behaviour.
  • ypr ay ap ar, e.g. "ypr 0.1 0 0": Using Euler angles for yaw-pitch-roll rotation, i.e. around axis Y, X and Z counter clockwise (right-handed), but by airplane convention with negative Y and Z, where every angle per default is expressed in radians.
  • axisangle x y z a, e.g. "axisangle 0 1 0 0.1": Using axis for rotation and angle of rotation around this axis, where the angle is expressed counter clockwise (right-handed) per default in radians. The axis does not have to be normalized.
  • angleaxis a x y z, e.g. "angleaxis 0.1 0 1 0": Using axis for rotation and angle of rotation around this axis, where the angle is expressed counter clockwise (right-handed) per default in radians. The axis does not have to be normalized.
See also
operator>>(std::istream &, gmCore::angle &)

◆ operator>>() [4/20]

std::istream & gramods::operator>> ( std::istream &  in,
Eigen::Vector2f &  v 
)

Stream operator reading two values into an Eigen::Vector2f.

This is typically used to read XML position and vector attributes. This will read three values (x y) from the stream.

◆ operator>>() [5/20]

std::istream & gramods::operator>> ( std::istream &  in,
Eigen::Vector3f &  v 
)

Stream operator reading three values into an Eigen::Vector3f.

This is typically used to read XML position and vector attributes. This will read three values (x y z) from the stream.

◆ operator>>() [6/20]

std::istream & gramods::operator>> ( std::istream &  in,
gmCore::angle v 
)

Stream operator reading into a angle.

This is typically used to read XML angle attributes. Default behavior is to read a single value in radians, but the value is interpreted as degrees if it is prepended by a 'd' (as in 'd180'). The value can also be prepended by an 'r' (as in r3.14) to suppress the warnings that degrees probably was ment for large values.

◆ operator>>() [7/20]

std::istream & gramods::operator>> ( std::istream &  in,
gmGraphics::Eye e 
)

Stream operator reading into an Eye.

This is typically used to read XML attributes. This will recognize "MONO", "LEFT" and "RIGHT".

◆ operator>>() [8/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::angle2 s 
)
inline

Stream operator reading two values into a angle2.

◆ operator>>() [9/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::angle3 s 
)
inline

Stream operator reading three values into a angle3.

◆ operator>>() [10/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::angle4 s 
)
inline

Stream operator reading four values into a angle4.

◆ operator>>() [11/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::float12 s 
)
inline

Stream operator reading 12 values into a float12.

◆ operator>>() [12/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::float2 s 
)
inline

Stream operator reading two values into a float2.

◆ operator>>() [13/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::float3 s 
)
inline

Stream operator reading three values into a float3.

◆ operator>>() [14/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::float4 s 
)
inline

Stream operator reading four values into a float4.

◆ operator>>() [15/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::int2 s 
)
inline

Stream operator reading two values into a int2.

◆ operator>>() [16/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::int3 s 
)
inline

Stream operator reading three values into a int3.

◆ operator>>() [17/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::int4 s 
)
inline

Stream operator reading four values into a int4.

◆ operator>>() [18/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::size2 s 
)
inline

Stream operator reading two values into a size2.

◆ operator>>() [19/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::size3 s 
)
inline

Stream operator reading three values into a size3.

◆ operator>>() [20/20]

std::istream& gramods::operator>> ( std::istream &  in,
gramods::gmCore::size4 s 
)
inline

Stream operator reading four values into a size4.

◆ SPEED_OF_SOUND()

const gmMisc::PolyFit gramods::SPEED_OF_SOUND ( {{35}, {30}, {25}, {20}, {15}, {10}, {5}, {0}, {-5}, {-10}, {-15}, {-20}, {-25}}  ,
{{351.88}, {349.02}, {346.13}, {343.21}, {340.27}, {337.31}, {334.32}, {331.30}, {328.25}, {325.18}, {322.07}, {318.94}, {315.77}}  ,
 
)

Second order approximation of the speed of sound in standard air, based on table at Wikipedia.

Variable Documentation

◆ SPEED_OF_SOUND_T0

constexpr float gramods::SPEED_OF_SOUND_T0 = 331.f
constexpr

The speed of sound in standard air at 0°C.

◆ SPEED_OF_SOUND_T20

constexpr float gramods::SPEED_OF_SOUND_T20 = 343.f
constexpr

The speed of sound in standard air at 20°C.