VTK
vtkOrderIndependentTranslucentPass.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOrderIndependentTranslucentPass.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
29 #ifndef vtkOrderIndependentTranslucentPass_h
30 #define vtkOrderIndependentTranslucentPass_h
31 
32 #include "vtkRenderingOpenGL2Module.h" // For export macro
33 #include "vtkOpenGLRenderPass.h"
34 
36 class vtkTextureObject;
38 class vtkOpenGLState;
40 
41 class VTKRENDERINGOPENGL2_EXPORT vtkOrderIndependentTranslucentPass
42  : public vtkOpenGLRenderPass
43 {
44 public:
47  void PrintSelf(ostream& os, vtkIndent indent) override;
48 
53  void Render(const vtkRenderState *s) override;
54 
60  void ReleaseGraphicsResources(vtkWindow *w) override;
61 
63 
69  vtkGetObjectMacro(TranslucentPass,vtkRenderPass);
70  virtual void SetTranslucentPass(vtkRenderPass *translucentPass);
72 
73  // vtkOpenGLRenderPass virtuals:
74  bool PostReplaceShaderValues(std::string &vertexShader,
75  std::string &geometryShader,
76  std::string &fragmentShader,
77  vtkAbstractMapper *mapper,
78  vtkProp *prop) override;
79 
80  protected:
85 
90 
92 
94 
97  int ViewportX;
98  int ViewportY;
102 
105 
109 
110  void BlendFinalPeel(vtkOpenGLRenderWindow *renWin);
111 
112  // useful to store
114 
115  private:
117  void operator=(const vtkOrderIndependentTranslucentPass&) = delete;
118 };
119 
120 #endif
OpenGL rendering window.
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:52
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int ViewportWidth
Cache viewport values for depth peeling.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:37
int ViewportY
Cache viewport values for depth peeling.
Context in which a vtkRenderPass will render.
OpenGL state storage.
a simple class to control print indentation
Definition: vtkIndent.h:39
Internal class which encapsulates OpenGL FramebufferObject.
abstract class specifies interface to map data
abstracts an OpenGL texture object.
virtual void Render(const vtkRenderState *s)=0
Perform rendering according to a render state s.
Class to make rendering a full screen quad easier.
virtual void ReleaseGraphicsResources(vtkWindow *w)
Release graphics resources and ask components to release their own resources.
int ViewportHeight
Cache viewport values for depth peeling.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
Perform part of the rendering of a vtkRenderer.
Definition: vtkRenderPass.h:58
Abstract render pass with shader modifications.
virtual bool PostReplaceShaderValues(std::string &vertexShader, std::string &geometryShader, std::string &fragmentShader, vtkAbstractMapper *mapper, vtkProp *prop)
Use vtkShaderProgram::Substitute to replace //VTK::XXX:YYY declarations in the shader sources...
int ViewportX
Cache viewport values for depth peeling.
Implement OIT rendering using average color.