Emergency 20 Dokumentation  4.1.0
Public Member Functions | Protected Attributes | List of all members
qsf::TextDebugDrawRequest Class Reference

Text debug draw request implementation. More...

#include <TextDebugDrawRequest.h>

Inheritance diagram for qsf::TextDebugDrawRequest:
Inheritance graph
[legend]
Collaboration diagram for qsf::TextDebugDrawRequest:
Collaboration graph
[legend]

Public Member Functions

 TextDebugDrawRequest (const std::string &text, const glm::vec2 &windowPosition, const Color4 &textColor=Color4::WHITE)
 Constructor. More...
 
 TextDebugDrawRequest (const std::string &text, const glm::vec3 &worldPosition, const Color4 &textColor=Color4::WHITE)
 Constructor. More...
 
 TextDebugDrawRequest (const std::string &text, const glm::vec2 &windowPosition, const DebugTextParameters &debugTextParameters)
 Constructor. More...
 
 TextDebugDrawRequest (const std::string &text, const glm::vec3 &worldPosition, const DebugTextParameters &debugTextParameters)
 Constructor. More...
 
virtual ~TextDebugDrawRequest ()
 Destructor. More...
 
virtual void applyToObject (DebugDrawObject &debugDrawObject) const override
 Apply this request to a debug draw object instance. More...
 

Protected Attributes

std::string mText
 The text to draw. More...
 
bool mUsingWorldPosition
 If "true", position is given in world coordinates, else 2D window coordinates. More...
 
glm::vec3 mPosition
 Position of the text in the 3D world space or on the screen. More...
 
DebugTextParameters mTextParameters
 Parameters defining how the text is formatted. More...
 

Additional Inherited Members

- Protected Member Functions inherited from qsf::DebugDrawRequest
 DebugDrawRequest ()
 Constructor. More...
 
virtual ~DebugDrawRequest ()
 Destructor. More...
 

Detailed Description

Text debug draw request implementation.

Todo:
  • TODO(vs) Uses a probably non portable friend declaration to hide an ugly default constructor creating an illegal state temporarily when used inside a std::vector

Constructor & Destructor Documentation

qsf::TextDebugDrawRequest::TextDebugDrawRequest ( const std::string &  text,
const glm::vec2 &  windowPosition,
const Color4 textColor = Color4::WHITE 
)
inline

Constructor.

Parameters
[in]textThe UTF-8 encoded text
[in]windowPositionThe position where to draw the text in 2D window coordinates
[in]textColorDraw color
qsf::TextDebugDrawRequest::TextDebugDrawRequest ( const std::string &  text,
const glm::vec3 &  worldPosition,
const Color4 textColor = Color4::WHITE 
)
inline

Constructor.

Parameters
[in]textThe UTF-8 encoded text
[in]worldPositionThe position where to draw the text in 3D world coordinates
[in]textColorDraw color
qsf::TextDebugDrawRequest::TextDebugDrawRequest ( const std::string &  text,
const glm::vec2 &  windowPosition,
const DebugTextParameters debugTextParameters 
)
inline

Constructor.

Parameters
[in]textThe UTF-8 encoded text
[in]windowPositionThe position where to draw the text in 2D window coordinates
[in]debugTextParametersDebug text parameters with special formatting options
qsf::TextDebugDrawRequest::TextDebugDrawRequest ( const std::string &  text,
const glm::vec3 &  worldPosition,
const DebugTextParameters debugTextParameters 
)
inline

Constructor.

Parameters
[in]textThe UTF-8 encoded text
[in]worldPositionThe position where to draw the text in 3D world coordinates
[in]debugTextParametersDebug text parameters with special formatting options
qsf::TextDebugDrawRequest::~TextDebugDrawRequest ( )
inlinevirtual

Destructor.

Member Function Documentation

virtual void qsf::TextDebugDrawRequest::applyToObject ( DebugDrawObject debugDrawObject) const
overridevirtual

Apply this request to a debug draw object instance.

Parameters
[in]debugDrawObjectDebugDrawObject instance to apply the request to

Implements qsf::DebugDrawRequest.

Member Data Documentation

glm::vec3 qsf::TextDebugDrawRequest::mPosition
protected

Position of the text in the 3D world space or on the screen.

std::string qsf::TextDebugDrawRequest::mText
protected

The text to draw.

DebugTextParameters qsf::TextDebugDrawRequest::mTextParameters
protected

Parameters defining how the text is formatted.

bool qsf::TextDebugDrawRequest::mUsingWorldPosition
protected

If "true", position is given in world coordinates, else 2D window coordinates.


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