SLProject
4.2.000
A platform independent 3D computer graphics framework for desktop OS, Android, iOS and online in web browsers
|
Wrapper around Oculus Rift and its Frame Buffer Objects. More...
#include <SLGLOculusFB.h>
Public Member Functions | |
SLGLOculusFB () | |
~SLGLOculusFB () | |
void | bindFramebuffer (SLint scrWidth, SLint scrHeight) |
void | drawFramebuffer (SLGLProgram *stereoOculusProgram) |
void | updateSize (SLint scrWidth, SLint scrHeight) |
SLint | width () |
SLint | halfWidth () |
SLint | height () |
SLuint | texID () |
Private Member Functions | |
void | dispose () |
void | generateFBO () |
Private Attributes | |
SLint | _width |
SLint | _height |
Width of the buffer. More... | |
SLint | _halfWidth |
Height of the buffer. More... | |
SLint | _halfHeight |
Half the width of the buffer. More... | |
SLuint | _fbID |
Half the height of the buffer. More... | |
SLuint | _depthRbID |
OpenGL id of frame buffer. More... | |
SLuint | _texID |
OpenGL id of depth render buffer. More... | |
SLGLVertexArray | _vao |
OpenGL id of. More... | |
Wrapper around Oculus Rift and its Frame Buffer Objects.
This class is deprecated since the lib_ovr from Oculus completely changed The lib_ovr that connects the Oculus hardware was removed since it only worked for devkit2 under windows.
Definition at line 24 of file SLGLOculusFB.h.
SLGLOculusFB::SLGLOculusFB | ( | ) |
Constructor initializing with default values
Definition at line 19 of file SLGLOculusFB.cpp.
SLGLOculusFB::~SLGLOculusFB | ( | ) |
Destructor calling dispose
Definition at line 32 of file SLGLOculusFB.cpp.
Activates the frame buffer. On the first time it calls the updateSize to determine the size and then creates the FBO.
Definition at line 49 of file SLGLOculusFB.cpp.
|
private |
void SLGLOculusFB::drawFramebuffer | ( | SLGLProgram * | stereoOculusProgram | ) |
Draws the intermediate render target (the texture) into the real framebuffer.
Definition at line 178 of file SLGLOculusFB.cpp.
|
private |
Frame Buffer generation. This is called from within updateSize because the frame buffer size has to be calculated first
Definition at line 61 of file SLGLOculusFB.cpp.
|
inline |
Definition at line 38 of file SLGLOculusFB.h.
|
inline |
Definition at line 39 of file SLGLOculusFB.h.
|
inline |
Definition at line 40 of file SLGLOculusFB.h.
Updates everything when the screen gets resized:
Definition at line 132 of file SLGLOculusFB.cpp.
|
inline |
Definition at line 37 of file SLGLOculusFB.h.
|
private |
OpenGL id of frame buffer.
Definition at line 51 of file SLGLOculusFB.h.
|
private |
Half the height of the buffer.
Definition at line 50 of file SLGLOculusFB.h.
|
private |
Half the width of the buffer.
Definition at line 49 of file SLGLOculusFB.h.
|
private |
Height of the buffer.
Definition at line 48 of file SLGLOculusFB.h.
|
private |
Width of the buffer.
Definition at line 47 of file SLGLOculusFB.h.
|
private |
OpenGL id of depth render buffer.
Definition at line 52 of file SLGLOculusFB.h.
|
private |
OpenGL id of.
Definition at line 53 of file SLGLOculusFB.h.
|
private |
Definition at line 46 of file SLGLOculusFB.h.