VTK
vtkOpenGLRenderPass.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOpenGLRenderPass.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 =========================================================================*/
15 
24 #ifndef vtkOpenGLRenderPass_h
25 #define vtkOpenGLRenderPass_h
26 
27 #include "vtkRenderingOpenGL2Module.h" // For export macro
28 #include "vtkRenderPass.h"
29 
30 #include <string> // For std::string
31 
32 class vtkAbstractMapper;
34 class vtkProp;
35 class vtkShaderProgram;
37 
38 class VTKRENDERINGOPENGL2_EXPORT vtkOpenGLRenderPass: public vtkRenderPass
39 {
40 public:
42  void PrintSelf(ostream &os, vtkIndent indent) VTK_OVERRIDE;
43 
49  virtual bool PreReplaceShaderValues(std::string &vertexShader,
50  std::string &geometryShader,
51  std::string &fragmentShader,
52  vtkAbstractMapper *mapper,
53  vtkProp *prop);
54 
60  virtual bool PostReplaceShaderValues(std::string &vertexShader,
61  std::string &geometryShader,
62  std::string &fragmentShader,
63  vtkAbstractMapper *mapper,
64  vtkProp *prop);
65 
70  virtual bool SetShaderParameters(vtkShaderProgram *program,
71  vtkAbstractMapper *mapper, vtkProp *prop,
72  vtkOpenGLVertexArrayObject *VAO = NULL);
73 
81  virtual vtkMTimeType GetShaderStageMTime();
82 
86  static vtkInformationObjectBaseVectorKey *RenderPasses();
87 
88 protected:
90  ~vtkOpenGLRenderPass() VTK_OVERRIDE;
91 
95  void PreRender(const vtkRenderState *s);
96 
100  void PostRender(const vtkRenderState *s);
101 
102 private:
103  vtkOpenGLRenderPass(const vtkOpenGLRenderPass&) VTK_DELETE_FUNCTION;
104  void operator=(const vtkOpenGLRenderPass&) VTK_DELETE_FUNCTION;
105 };
106 
107 #endif // vtkOpenGLRenderPass_h
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:44
vtkTypeUInt32 vtkMTimeType
Definition: vtkType.h:300
Context in which a vtkRenderPass will render.
a simple class to control print indentation
Definition: vtkIndent.h:33
The VertexArrayObject class uses, or emulates, vertex array objects.
Key for vtkObjectBase vector values.
abstract class specifies interface to map data
Perform part of the rendering of a vtkRenderer.
Definition: vtkRenderPass.h:55
Abstract render pass with shader modifications.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
The ShaderProgram uses one or more Shader objects.