VR-Vantage
Loading...
Searching...
No Matches
OculusTextureBuffer Class Reference
Inheritance diagram for OculusTextureBuffer:

Public Member Functions

 OculusTextureBuffer (const ovrSession &session, osg::ref_ptr< osg::State > state, const ovrSizei &size, int msaaSamples)
void destroy ()
int textureWidth () const
int textureHeight () const
int samples () const
ovrTextureSwapChain textureSwapChain () const
osg::ref_ptr< osg::Texture2D > colorBuffer () const
osg::ref_ptr< osg::Texture2D > depthBuffer () const
void onPreRender (osg::RenderInfo &renderInfo)
void onPostRender (osg::RenderInfo &renderInfo)
void setEnableTextureBlit (bool set, int x, int y)

Protected Member Functions

virtual ~OculusTextureBuffer ()
GLuint createProgram (const std::string &name)
void blitTexture (osg::State *state, int width, int height)
void setup (osg::State &state)
void setupMSAA (osg::State &state)

Protected Attributes

const ovrSession m_session
ovrTextureSwapChain m_textureSwapChain
osg::ref_ptr< osg::Texture2D > m_colorBuffer
osg::ref_ptr< osg::Texture2D > m_depthBuffer
osg::Vec2i m_textureSize
GLuint m_Oculus_FBO
GLuint m_MSAA_FBO
GLuint m_MSAA_ColorTex
GLuint m_MSAA_DepthTex
int m_samples
GLuint myCurrentTextureId
bool myShouldBlitTexture
GLuint myDownsampleShader
int myBlitWidth
int myBlitHeight

Constructor & Destructor Documentation

◆ OculusTextureBuffer()

OculusTextureBuffer::OculusTextureBuffer ( const ovrSession & session,
osg::ref_ptr< osg::State > state,
const ovrSizei & size,
int msaaSamples )

◆ ~OculusTextureBuffer()

virtual OculusTextureBuffer::~OculusTextureBuffer ( )
inlineprotectedvirtual

Member Function Documentation

◆ destroy()

void OculusTextureBuffer::destroy ( )

◆ textureWidth()

int OculusTextureBuffer::textureWidth ( ) const
inline

References m_textureSize.

◆ textureHeight()

int OculusTextureBuffer::textureHeight ( ) const
inline

References m_textureSize.

◆ samples()

int OculusTextureBuffer::samples ( ) const
inline

References m_samples.

◆ textureSwapChain()

ovrTextureSwapChain OculusTextureBuffer::textureSwapChain ( ) const
inline

References m_textureSwapChain.

◆ colorBuffer()

osg::ref_ptr< osg::Texture2D > OculusTextureBuffer::colorBuffer ( ) const
inline

References m_colorBuffer.

◆ depthBuffer()

osg::ref_ptr< osg::Texture2D > OculusTextureBuffer::depthBuffer ( ) const
inline

References m_depthBuffer.

◆ onPreRender()

void OculusTextureBuffer::onPreRender ( osg::RenderInfo & renderInfo)

◆ onPostRender()

void OculusTextureBuffer::onPostRender ( osg::RenderInfo & renderInfo)

◆ setEnableTextureBlit()

void OculusTextureBuffer::setEnableTextureBlit ( bool set,
int x,
int y )

◆ createProgram()

GLuint OculusTextureBuffer::createProgram ( const std::string & name)
protected

◆ blitTexture()

void OculusTextureBuffer::blitTexture ( osg::State * state,
int width,
int height )
protected

◆ setup()

void OculusTextureBuffer::setup ( osg::State & state)
protected

◆ setupMSAA()

void OculusTextureBuffer::setupMSAA ( osg::State & state)
protected

Member Data Documentation

◆ m_session

const ovrSession OculusTextureBuffer::m_session
protected

◆ m_textureSwapChain

ovrTextureSwapChain OculusTextureBuffer::m_textureSwapChain
protected

Referenced by textureSwapChain().

◆ m_colorBuffer

osg::ref_ptr<osg::Texture2D> OculusTextureBuffer::m_colorBuffer
protected

Referenced by colorBuffer().

◆ m_depthBuffer

osg::ref_ptr<osg::Texture2D> OculusTextureBuffer::m_depthBuffer
protected

Referenced by depthBuffer().

◆ m_textureSize

osg::Vec2i OculusTextureBuffer::m_textureSize
protected

Referenced by textureHeight(), and textureWidth().

◆ m_Oculus_FBO

GLuint OculusTextureBuffer::m_Oculus_FBO
protected

◆ m_MSAA_FBO

GLuint OculusTextureBuffer::m_MSAA_FBO
protected

◆ m_MSAA_ColorTex

GLuint OculusTextureBuffer::m_MSAA_ColorTex
protected

◆ m_MSAA_DepthTex

GLuint OculusTextureBuffer::m_MSAA_DepthTex
protected

◆ m_samples

int OculusTextureBuffer::m_samples
protected

Referenced by samples().

◆ myCurrentTextureId

GLuint OculusTextureBuffer::myCurrentTextureId
protected

◆ myShouldBlitTexture

bool OculusTextureBuffer::myShouldBlitTexture
protected

◆ myDownsampleShader

GLuint OculusTextureBuffer::myDownsampleShader
protected

◆ myBlitWidth

int OculusTextureBuffer::myBlitWidth
protected

◆ myBlitHeight

int OculusTextureBuffer::myBlitHeight
protected

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