float SLfloat
analog to GLfloat
unsigned int SLuint
analog to GLuint
bool SLbool
analog to GLbool
string SLstring
Redefinition of standard types for platform independence.
SLEyeType
Enumeration for stereo eye type used for camera projection.
vector< SLVertexOculus > SLVVertexOculus
Wrapper around Oculus Rift Devkit 2.
SLbool isLowPersistanceEnabled()
void positionTracking(SLbool val)
SLbool isPositionTracked()
const SLVec3f & viewAdjust(SLEyeType eye)
const SLQuat4f & orientation(SLEyeType eye)
void lowPersistance(SLbool val)
SLbool _hmdSettingsChanged
settings need to be updated flag
const SLVec3f & position(SLEyeType eye)
SLbool _usingDebugHmd
we're using a debug HMD
SLVec2i _resolution
Resolution of the HMD.
SLVec3f _viewAdjust[2]
view adjust vector
SLfloat resolutionScale()
SLGLVertexArray _distortionMeshVAO[2]
distortion meshes for left and right eye
const SLMat4f & orthoProjection(SLEyeType eye)
const SLMat4f & projection(SLEyeType eye)
void renderDistortion(SLint width, SLint height, SLuint tex, const SLCol4f &background)
SLbool isCameraConnected()
SLVec2i _outputRes
output resolution used for ortho projection
SLVec3f _position[2]
eye position
SLbool isTimeWarpEnabled()
SLVec2i _rtSize
Required resolution for the render target.
SLbool isPositionTrackingEnabled()
SLMat4f _projection[2]
projection matrices for left and right eye
void calculateHmdValues()
recalculate HMD settings changed
SLbool _isConnected
is HMD connected
SLbool _displaySleep
is the display of the rift currently off
SLbool _timeWarpEnabled
time warp correction enabled
SLbool _lowPersistanceEnabled
low persistence rendering enabled
SLQuat4f _orientation[2]
eye orientation
SLGLOculus(SLstring shaderDir)
SLfloat _resolutionScale
required resolution scale for a 1.0 min pixel density
void timeWarp(SLbool val)
SLGLProgram * _stereoOculusDistProgram
void renderResolution(SLint width, SLint height)
void displaySleep(SLbool val)
SLbool _isPositionTracked
is the position tracked (false if out of range)
SLbool _isCameraConnected
is position tracker camera connected
SLMat4f _orthoProjection[2]
projection for 2d elements
SLbool _positionTrackingEnabled
is position tracking enabled
Encapsulation of an OpenGL shader program object.
SLGLVertexArray encapsulates the core OpenGL drawing.
Distorted vertex used to draw in the Oculus frame buffer.