MVE - Multi-View Environment mve-devel
Loading...
Searching...
No Matches
Classes | Typedefs | Enumerations | Functions
ogl Namespace Reference

Wrappers and helpers for the OpenGL graphics API. More...

Classes

class  Cam2D
 
class  Camera
 A camera class that manages viewing and projection matrices. More...
 
class  CameraContext
 A simple context that does some of the common annoying work. More...
 
class  CamTrackball
 A trackball camera control that consumes mouse events and delivers viewing parameters for the camera. More...
 
class  Context
 Abstraction of a rendering context/viewport that displays renderings. More...
 
struct  KeyboardEvent
 Keyboard event. More...
 
class  MeshRenderer
 OpenGL renderer that takes a mesh and automatically creates the appropriate VBOs and a vertex array object. More...
 
struct  MouseEvent
 Mouse event. More...
 
class  ShaderProgram
 Abstraction for OpenGL Shader Programs. More...
 
class  Texture
 OpenGL texture abstraction. More...
 
class  VertexArray
 OpenGL vertex array object abstraction. More...
 
class  VertexBuffer
 OpenGL vertex buffer object (VBO) abstraction. More...
 

Typedefs

typedef CameraContext< Cam2DCameraPlanarContext
 
typedef CameraContext< CamTrackballCameraTrackballContext
 

Enumerations

enum  KeyboardEventType { KEYBOARD_EVENT_PRESS , KEYBOARD_EVENT_RELEASE }
 Keyboard event type. More...
 
enum  MouseButton {
  MOUSE_BUTTON_NONE = 0 , MOUSE_BUTTON_LEFT = 1 << 0 , MOUSE_BUTTON_RIGHT = 1 << 1 , MOUSE_BUTTON_MIDDLE = 1 << 2 ,
  MOUSE_BUTTON_X1 = 1 << 3 , MOUSE_BUTTON_X2 = 1 << 4
}
 Mouse button types. More...
 
enum  MouseEventType {
  MOUSE_EVENT_PRESS , MOUSE_EVENT_RELEASE , MOUSE_EVENT_MOVE , MOUSE_EVENT_WHEEL_UP ,
  MOUSE_EVENT_WHEEL_DOWN
}
 Mouse event types. More...
 

Functions

void check_gl_error ()
 
VertexArray::Ptr create_axis_renderer (ShaderProgram::Ptr shader)
 Generates a vertex array for visualizing the three world coordinate axis.
 
VertexArray::Ptr create_fullscreen_quad (ShaderProgram::Ptr shader)
 Generates a full screen quad renderer in OpenGL unit coordinates.
 
void event_debug_print (KeyboardEvent const &e)
 Prints debug information for keyboard event 'e' to STDOUT.
 
void event_debug_print (MouseEvent const &e)
 Prints debug information for mouse event 'e' to STDOUT.
 

Detailed Description

Wrappers and helpers for the OpenGL graphics API.

Typedef Documentation

◆ CameraPlanarContext

Definition at line 81 of file context.h.

◆ CameraTrackballContext

Definition at line 80 of file context.h.

Enumeration Type Documentation

◆ KeyboardEventType

Keyboard event type.

Enumerator
KEYBOARD_EVENT_PRESS 
KEYBOARD_EVENT_RELEASE 

Definition at line 49 of file events.h.

◆ MouseButton

Mouse button types.

Enumerator
MOUSE_BUTTON_NONE 
MOUSE_BUTTON_LEFT 
MOUSE_BUTTON_RIGHT 
MOUSE_BUTTON_MIDDLE 
MOUSE_BUTTON_X1 
MOUSE_BUTTON_X2 

Definition at line 28 of file events.h.

◆ MouseEventType

Mouse event types.

Enumerator
MOUSE_EVENT_PRESS 
MOUSE_EVENT_RELEASE 
MOUSE_EVENT_MOVE 
MOUSE_EVENT_WHEEL_UP 
MOUSE_EVENT_WHEEL_DOWN 

Definition at line 18 of file events.h.

Function Documentation

◆ check_gl_error()

void ogl::check_gl_error ( )
inline

Definition at line 22 of file check_gl_error.h.

◆ create_axis_renderer()

VertexArray::Ptr ogl::create_axis_renderer ( ShaderProgram::Ptr  shader)

Generates a vertex array for visualizing the three world coordinate axis.

You need to specify your own shader, where you can also apply additional transformations, for example to visualize local coordinate system.

Definition at line 17 of file render_tools.cc.

◆ create_fullscreen_quad()

VertexArray::Ptr ogl::create_fullscreen_quad ( ShaderProgram::Ptr  shader)

Generates a full screen quad renderer in OpenGL unit coordinates.

The quad vertices have coordiantes (+-1, +-1, 0) with normals (0, 0, 1) and texture coordiantes (0/1, 0/1).

Definition at line 91 of file render_tools.cc.

◆ event_debug_print() [1/2]

void ogl::event_debug_print ( ogl::KeyboardEvent const &  event)

Prints debug information for keyboard event 'e' to STDOUT.

Definition at line 49 of file events.cc.

◆ event_debug_print() [2/2]

void ogl::event_debug_print ( ogl::MouseEvent const &  event)

Prints debug information for mouse event 'e' to STDOUT.

Definition at line 18 of file events.cc.