All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Static Public Member Functions | Static Private Member Functions | Static Private Attributes | List of all members
GlutRenderer Class Reference

Simple static class renderer built on Glut. More...

#include <SurgSim/Testing/VisualTestCommon/GlutRenderer.h>

Collaboration diagram for GlutRenderer:
Collaboration graph
[legend]

Static Public Member Functions

static void run ()
 Initializes and runs the Glut main loop. This function will block until the Glut graphics window is closed. More...
 
static void setCamera (std::shared_ptr< GlutCamera > camera)
 Sets the camera used to control the view of the scene. More...
 
static void addObject (std::shared_ptr< GlutRenderObject > object)
 Adds an object to the scene. More...
 

Static Private Member Functions

static void initialize ()
 Initializes the Glut window. More...
 
static void reshape (GLint width, GLint height)
 Glut reshape function which handles the resizing of the window. More...
 
static void display ()
 Glut display function which handles the drawing of the scene. More...
 
static void drawObjects ()
 Iterates through the scene objects to draw them. More...
 

Static Private Attributes

static int m_width = 1024
 Width of the window. More...
 
static int m_height = 768
 Height of the window. More...
 
static std::shared_ptr
< GlutCamera
m_camera = nullptr
 Camera which controls the view of the scene. More...
 
static std::vector
< std::shared_ptr
< GlutRenderObject > > 
m_objects
 Objects in the scene. More...
 

Detailed Description

Simple static class renderer built on Glut.

Member Function Documentation

static void GlutRenderer::addObject ( std::shared_ptr< GlutRenderObject object)
inlinestatic

Adds an object to the scene.

Parameters
objectScene object.
void GlutRenderer::display ( )
staticprivate

Glut display function which handles the drawing of the scene.

static void GlutRenderer::drawObjects ( )
inlinestaticprivate

Iterates through the scene objects to draw them.

void GlutRenderer::initialize ( )
staticprivate

Initializes the Glut window.

static void GlutRenderer::reshape ( GLint  width,
GLint  height 
)
inlinestaticprivate

Glut reshape function which handles the resizing of the window.

static void GlutRenderer::run ( )
inlinestatic

Initializes and runs the Glut main loop. This function will block until the Glut graphics window is closed.

static void GlutRenderer::setCamera ( std::shared_ptr< GlutCamera camera)
inlinestatic

Sets the camera used to control the view of the scene.

Parameters
cameraView camera.

Member Data Documentation

std::shared_ptr< GlutCamera > GlutRenderer::m_camera = nullptr
staticprivate

Camera which controls the view of the scene.

int GlutRenderer::m_height = 768
staticprivate

Height of the window.

std::vector< std::shared_ptr< GlutRenderObject > > GlutRenderer::m_objects
staticprivate

Objects in the scene.

int GlutRenderer::m_width = 1024
staticprivate

Width of the window.


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