12.07.2015 Views

4D Volume Rendering - Nvidia

4D Volume Rendering - Nvidia

4D Volume Rendering - Nvidia

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Multi-pass raycasting - OpenGLFBOFrontfaceTextureBackfaceTexturePass 1Rasterizeboundbox’sPass 2RaycastFragshaderImage PlaneInit offscreen FBO and the 2 texturesglGenFramebuffersEXT(1, &FBO);glBindFramebufferEXT(GL_FRAMEBUFFER_EXT, FBO);glGenTextures(1, &BackfaceTexture); //The texture where the backface of the volume bounding cube is rendered toglBindTexture(GL_TEXTURE_2D, BackfaceTexture);glTexImage2D(GL_TEXTURE_2D, 0,GL_RGBA16F_ARB, winWidth, winHeight, 0, GL_RGBA, GL_FLOAT, NULL);glGenTextures(1, &FrontfaceTexture); //The texture that has the front face imageglBindTexture(GL_TEXTURE_2D, FrontfaceTexture);glTexImage2D(GL_TEXTURE_2D, 0,GL_RGBA16F_ARB, winWidth, winHeight, 0, GL_RGBA, GL_FLOAT, NULL);

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!