Ketchup Engine
Loading...
Searching...
No Matches
Visualizer Class Reference

#include <Visualizer.h>

Collaboration diagram for Visualizer:
Collaboration graph

Public Types

using CommandList = std::list< VisualizerCommand * >
 

Static Public Member Functions

static void ShowCollisionVolume (const CollisionVolume &vol, const Vect &col=m_defaultColor)
 Queues a command to draw CollisionVolume during draw phase of this frame.
 
static void ShowBSphere (const BSphere &bs, const Vect &col=m_defaultColor)
 Queues a command to draw BSphere during draw phase of this frame.
 
static void ShowAABB (const AABB &aabb, const Vect &col=m_defaultColor)
 Queues a command to draw AABB during draw phase of this frame.
 
static void ShowPoint (const Vect &pos, float rad, const Vect &col=m_defaultColor)
 Queues a command to draw a point during draw phase of this frame.
 
static void ShowPipe (const Vect &pos1, const Vect &pos2, float rad, const Vect &col=m_defaultColor)
 Queues a command to draw a pipe between to points during draw phase of this frame.
 

Private Member Functions

 Visualizer ()
 
 Visualizer (const Visualizer &)=delete
 
Visualizeroperator= (const Visualizer &)=delete
 
virtual ~Visualizer ()
 

Static Private Member Functions

static VisualizerInstance ()
 
static void Free ()
 
static void RenderAll ()
 
static void privRenderBSphere (const BSphere &s, const Vect &col)
 
static void privRenderAABB (const AABB &aabb, const Vect &col)
 
static void privRenderPoint (const Vect &pos, float rad, const Vect &col)
 
static void privRenderPipe (const Vect &pos1, const Vect &pos2, float rad, const Vect &col)
 

Private Attributes

GraphicsObject_WireframeConstantColor * pGObj_unitSphere
 
GraphicsObject_WireframeConstantColor * pGObj_unitBox
 
CommandList m_commands
 
VisualizerCommandFactory m_cmdFac
 

Static Private Attributes

static Visualizerp_instance
 
static Vect m_defaultColor
 

Friends

class VisualizerAttorney
 

Member Typedef Documentation

◆ CommandList

Constructor & Destructor Documentation

◆ Visualizer() [1/2]

Visualizer::Visualizer ( )
private

◆ Visualizer() [2/2]

Visualizer::Visualizer ( const Visualizer )
privatedelete

◆ ~Visualizer()

Visualizer::~Visualizer ( )
privatevirtual

Member Function Documentation

◆ Free()

void Visualizer::Free ( )
staticprivate

◆ Instance()

Visualizer * Visualizer::Instance ( )
staticprivate

◆ operator=()

Visualizer & Visualizer::operator= ( const Visualizer )
privatedelete

◆ privRenderAABB()

void Visualizer::privRenderAABB ( const AABB aabb,
const Vect &  col 
)
staticprivate

◆ privRenderBSphere()

void Visualizer::privRenderBSphere ( const BSphere s,
const Vect &  col 
)
staticprivate

◆ privRenderPipe()

void Visualizer::privRenderPipe ( const Vect &  pos1,
const Vect &  pos2,
float  rad,
const Vect &  col 
)
staticprivate

◆ privRenderPoint()

void Visualizer::privRenderPoint ( const Vect &  pos,
float  rad,
const Vect &  col 
)
staticprivate

◆ RenderAll()

void Visualizer::RenderAll ( )
staticprivate

◆ ShowAABB()

void Visualizer::ShowAABB ( const AABB aabb,
const Vect &  col = m_defaultColor 
)
static

Queues a command to draw AABB during draw phase of this frame.

Haru, 4/12/2023.

Parameters
aabbThe AABB.
col(Optional) The color of the wireframe.

◆ ShowBSphere()

void Visualizer::ShowBSphere ( const BSphere bs,
const Vect &  col = m_defaultColor 
)
static

Queues a command to draw BSphere during draw phase of this frame.

Haru, 3/19/2023.

Parameters
bsThe BSphere.
col(Optional) The color of the wireframe.

◆ ShowCollisionVolume()

void Visualizer::ShowCollisionVolume ( const CollisionVolume vol,
const Vect &  col = m_defaultColor 
)
static

Queues a command to draw CollisionVolume during draw phase of this frame.

Haru, 4/12/2023.

Parameters
bsThe CollisionVolume.
col(Optional) The color of the wireframe.

◆ ShowPipe()

void Visualizer::ShowPipe ( const Vect &  pos1,
const Vect &  pos2,
float  rad,
const Vect &  col = m_defaultColor 
)
static

Queues a command to draw a pipe between to points during draw phase of this frame.

Haru, 3/19/2023.

Parameters
pos1The start position.
pos2The end position.
radThe radius of the pipe.
col(Optional) The color of the wireframe.

◆ ShowPoint()

void Visualizer::ShowPoint ( const Vect &  pos,
float  rad,
const Vect &  col = m_defaultColor 
)
static

Queues a command to draw a point during draw phase of this frame.

Haru, 3/19/2023.

Parameters
posThe position of the point.
radThe radius of the p_aabb.
col(Optional) The color of the wireframe.

Friends And Related Function Documentation

◆ VisualizerAttorney

friend class VisualizerAttorney
friend

Member Data Documentation

◆ m_cmdFac

VisualizerCommandFactory Visualizer::m_cmdFac
private

◆ m_commands

CommandList Visualizer::m_commands
private

◆ m_defaultColor

Vect Visualizer::m_defaultColor
staticprivate

◆ p_instance

Visualizer * Visualizer::p_instance
staticprivate

◆ pGObj_unitBox

GraphicsObject_WireframeConstantColor* Visualizer::pGObj_unitBox
private

◆ pGObj_unitSphere

GraphicsObject_WireframeConstantColor* Visualizer::pGObj_unitSphere
private

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