Recast Navigation
Navigation-mesh Toolset for Games
BuildContext Class Reference

Recast build context. More...

#include <SampleInterfaces.h>

Inheritance diagram for BuildContext:
rcContext

Public Member Functions

 BuildContext ()
 
void dumpLog (const char *format,...)
 Dumps the log to stdout. More...
 
int getLogCount () const
 Returns number of log messages. More...
 
const char * getLogText (const int i) const
 Returns log message text. More...
 
- Public Member Functions inherited from rcContext
 rcContext (bool state=true)
 Constructor. More...
 
virtual ~rcContext ()
 
void enableLog (bool state)
 Enables or disables logging. More...
 
void resetLog ()
 Clears all log entries. More...
 
void log (const rcLogCategory category, const char *format,...)
 Logs a message. More...
 
void enableTimer (bool state)
 Enables or disables the performance timers. More...
 
void resetTimers ()
 Clears all performance timers. (Resets all to unused.) More...
 
void startTimer (const rcTimerLabel label)
 Starts the specified performance timer. More...
 
void stopTimer (const rcTimerLabel label)
 Stops the specified performance timer. More...
 
int getAccumulatedTime (const rcTimerLabel label) const
 Returns the total accumulated time of the specified performance timer. More...
 

Protected Member Functions

virtual void doResetLog ()
 Virtual functions for custom implementations. More...
 
virtual void doLog (const rcLogCategory category, const char *msg, const int len)
 Logs a message. More...
 
virtual void doResetTimers ()
 Clears all timers. (Resets all to unused.) More...
 
virtual void doStartTimer (const rcTimerLabel label)
 Starts the specified performance timer. More...
 
virtual void doStopTimer (const rcTimerLabel label)
 Stops the specified performance timer. More...
 
virtual int doGetAccumulatedTime (const rcTimerLabel label) const
 Returns the total accumulated time of the specified performance timer. More...
 

Additional Inherited Members

- Protected Attributes inherited from rcContext
bool m_logEnabled
 True if logging is enabled. More...
 
bool m_timerEnabled
 True if the performance timers are enabled. More...
 

Description

Recast build context.

Constructor & Destructor Documentation

◆ BuildContext()

BuildContext::BuildContext ( )

Member Function Documentation

◆ doGetAccumulatedTime()

int BuildContext::doGetAccumulatedTime ( const rcTimerLabel  label) const
protectedvirtual

Returns the total accumulated time of the specified performance timer.

Parameters
[in]labelThe category of the timer.
Returns
The accumulated time of the timer, or -1 if timers are disabled or the timer has never been started.

Reimplemented from rcContext.

◆ doLog()

void BuildContext::doLog ( const rcLogCategory  category,
const char *  msg,
const int  len 
)
protectedvirtual

Logs a message.

Parameters
[in]categoryThe category of the message.
[in]msgThe formatted message.
[in]lenThe length of the formatted message.

Reimplemented from rcContext.

◆ doResetLog()

void BuildContext::doResetLog ( )
protectedvirtual

Virtual functions for custom implementations.

Reimplemented from rcContext.

◆ doResetTimers()

void BuildContext::doResetTimers ( )
protectedvirtual

Clears all timers. (Resets all to unused.)

Reimplemented from rcContext.

◆ doStartTimer()

void BuildContext::doStartTimer ( const rcTimerLabel  label)
protectedvirtual

Starts the specified performance timer.

Parameters
[in]labelThe category of timer.

Reimplemented from rcContext.

◆ doStopTimer()

void BuildContext::doStopTimer ( const rcTimerLabel  label)
protectedvirtual

Stops the specified performance timer.

Parameters
[in]labelThe category of the timer.

Reimplemented from rcContext.

◆ dumpLog()

void BuildContext::dumpLog ( const char *  format,
  ... 
)

Dumps the log to stdout.

◆ getLogCount()

int BuildContext::getLogCount ( ) const

Returns number of log messages.

◆ getLogText()

const char * BuildContext::getLogText ( const int  i) const

Returns log message text.


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