79#ifndef vtkOpenGLGPUVolumeRayCastMapper_h
80#define vtkOpenGLGPUVolumeRayCastMapper_h
85#include "vtkRenderingVolumeOpenGL2Module.h"
92class vtkOpenGLTransferFunctions2D;
93class vtkOpenGLVolumeGradientOpacityTables;
94class vtkOpenGLVolumeOpacityTables;
95class vtkOpenGLVolumeRGBTables;
147 vtkGetMacro(CurrentPass,
int);
197 double vtkNotUsed(datasetBounds)[6],
double vtkNotUsed(scalarRange)[2],
198 int vtkNotUsed(noOfComponents),
unsigned int vtkNotUsed(numberOfLevels))
override
204 unsigned int vtkNotUsed(
level))
override
258 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
267 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
269 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
271 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
273 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
275 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
277 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
279 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
281 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
283 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkRenderer* ren,
vtkVolume* vol,
int numComps);
285 std::map<vtkShader::Type, vtkShader*>& shaders,
vtkVolume* vol,
bool prePass);
Ray casting performed on the GPU.
topologically and geometrically regular array of data
abstract interface for implicit functions
a simple class to control print indentation
OpenGL implementation of volume rendering through ray-casting.
void GetColorImage(vtkImageData *im) override
Low level API to export the color texture as vtkImageData in RenderToImage mode.
void ReplaceShaderRTT(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void SetShaderParametersRenderPass()
Update parameters from RenderPass.
void PreRender(vtkRenderer *vtkNotUsed(ren), vtkVolume *vtkNotUsed(vol), double vtkNotUsed(datasetBounds)[6], double vtkNotUsed(scalarRange)[2], int vtkNotUsed(noOfComponents), unsigned int vtkNotUsed(numberOfLevels)) override
void ReplaceShaderCustomUniforms(std::map< vtkShader::Type, vtkShader * > &shaders, vtkOpenGLShaderProperty *p)
RenderPass string replacements on shader templates called from ReplaceShaderValues.
void GetShaderTemplate(std::map< vtkShader::Type, vtkShader * > &shaders, vtkOpenGLShaderProperty *p)
Create the basic shader template strings before substitutions.
void GetDepthImage(vtkImageData *im) override
Low level API to export the depth texture as vtkImageData in RenderToImage mode.
void BuildShader(vtkRenderer *ren)
void ReplaceShaderCropping(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void ReplaceShaderRenderPass(std::map< vtkShader::Type, vtkShader * > &shaders, vtkVolume *vol, bool prePass)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void DoGPURender(vtkRenderer *ren, vtkOpenGLCamera *cam, vtkShaderProgram *shaderProgram, vtkOpenGLShaderProperty *shaderProperty)
std::map< int, vtkVolumeInputHelper > VolumeInputMap
bool PreLoadData(vtkRenderer *ren, vtkVolume *vol)
Load the volume texture into GPU memory.
void ReplaceShaderTermination(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void RenderBlock(vtkRenderer *vtkNotUsed(ren), vtkVolume *vtkNotUsed(vol), unsigned int vtkNotUsed(level)) override
void PostRender(vtkRenderer *vtkNotUsed(ren), int vtkNotUsed(noOfComponents)) override
void SetSharedDepthTexture(vtkTextureObject *nt)
void ComputeReductionFactor(double allocatedTime)
vtkOpenGLGPUVolumeRayCastMapper()
void ReplaceShaderPicking(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
~vtkOpenGLGPUVolumeRayCastMapper() override
void ReplaceShaderBase(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void GetReductionRatio(double *ratio) override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ReplaceShaderClipping(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
vtkMTimeType GetRenderPassStageMTime(vtkVolume *vol)
vtkOpenGLRenderPass API
vtkTextureObject * GetColorTexture()
void ReplaceShaderCompute(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void ReplaceShaderMasking(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
void BuildDepthPassShader(vtkRenderer *ren, vtkVolume *vol, int noOfComponents, int independentComponents)
vtkGenericOpenGLResourceFreeCallback * ResourceCallback
void SetPartitions(unsigned short x, unsigned short y, unsigned short z)
Set a fixed number of partitions in which to split the volume during rendring.
vtkNew< vtkInformation > LastRenderPassInfo
Caches the vtkOpenGLRenderPass::RenderPasses() information.
vtkTextureObject * GetDepthTexture()
void GPURender(vtkRenderer *ren, vtkVolume *vol) override
Handled in the subclass - the actual render method.
static vtkOpenGLGPUVolumeRayCastMapper * New()
void ReplaceShaderValues(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Perform string replacements on the shader templates.
void ReleaseGraphicsResources(vtkWindow *window) override
Release any graphics resources that are being consumed by this mapper.
void ReplaceShaderShading(std::map< vtkShader::Type, vtkShader * > &shaders, vtkRenderer *ren, vtkVolume *vol, int numComps)
Caches the vtkOpenGLRenderPass::RenderPasses() information.
int IsRenderSupported(vtkRenderWindow *vtkNotUsed(window), vtkVolumeProperty *vtkNotUsed(property)) override
Based on hardware and properties, we may or may not be able to render using 3D texture mapping.
VolumeInputMap AssembledInputs
represent GPU shader properties
create a window for renderers to draw into
abstract specification for renderers
The ShaderProgram uses one or more Shader objects.
abstracts an OpenGL texture object.
represents the common properties for rendering a volume.
Creates and manages the volume texture rendered by vtkOpenGLGPUVolumeRayCastMapper.
represents a volume (data & properties) in a rendered scene
window superclass for vtkRenderWindow
vtkTypeUInt32 vtkMTimeType