VTK  9.3.1
vtkOpenGLImageAlgorithmHelper.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
10 #ifndef vtkOpenGLImageAlgorithmHelper_h
11 #define vtkOpenGLImageAlgorithmHelper_h
12 
13 #include "vtkObject.h"
14 #include "vtkRenderingOpenGL2Module.h" // For export macro
15 
16 #include "vtkOpenGLHelper.h" // used for ivars
17 #include "vtkSmartPointer.h" // for ivar
18 
19 VTK_ABI_NAMESPACE_BEGIN
21 class vtkRenderWindow;
22 class vtkImageData;
23 class vtkDataArray;
24 
26 {
27 public:
28  virtual void InitializeShaderUniforms(vtkShaderProgram* /* program */) {}
29  virtual void UpdateShaderUniforms(vtkShaderProgram* /* program */, int /* zExtent */) {}
30  virtual ~vtkOpenGLImageAlgorithmCallback() = default;
32 
33 private:
35  void operator=(const vtkOpenGLImageAlgorithmCallback&) = delete;
36 };
37 
38 class VTKRENDERINGOPENGL2_EXPORT vtkOpenGLImageAlgorithmHelper : public vtkObject
39 {
40 public:
43  void PrintSelf(ostream& os, vtkIndent indent) override;
44 
45  void Execute(vtkOpenGLImageAlgorithmCallback* cb, vtkImageData* inImage, vtkDataArray* inData,
46  vtkImageData* outData, int outExt[6], const char* vertexCode, const char* fragmentCode,
47  const char* geometryCode);
48 
52  void SetRenderWindow(vtkRenderWindow* renWin);
53 
54 protected:
57 
60 
61 private:
63  void operator=(const vtkOpenGLImageAlgorithmHelper&) = delete;
64 };
65 
66 VTK_ABI_NAMESPACE_END
67 #endif
OpenGL rendering window.
abstract base class for most VTK objects
Definition: vtkObject.h:51
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
Help image algorithms use the GPU.
a simple class to control print indentation
Definition: vtkIndent.h:28
topologically and geometrically regular array of data
Definition: vtkImageData.h:42
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:44
vtkSmartPointer< vtkOpenGLRenderWindow > RenderWindow
create a window for renderers to draw into
virtual void InitializeShaderUniforms(vtkShaderProgram *)
virtual ~vtkOpenGLImageAlgorithmCallback()=default
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
virtual void UpdateShaderUniforms(vtkShaderProgram *, int)
The ShaderProgram uses one or more Shader objects.