VTK: Rendering/OpenGL2/vtkOpenGLHelper.h Source File

| VTK 9.3.1

vtkOpenGLHelper.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
3
4 #ifndef vtkOpenGLHelper_h
5 #define vtkOpenGLHelper_h
6
7 #include "vtkRenderingOpenGL2Module.h" // for export macro
8 #include "vtkTimeStamp.h"
9
10 VTK_ABI_NAMESPACE_BEGIN
11 class vtkOpenGLIndexBufferObject;
12 class vtkOpenGLShaderCache;
13 class vtkOpenGLVertexArrayObject;
14 class vtkShaderProgram;
15 class vtkWindow;
16
17 // Store the shaders, program, and ibo in a common place
18 // as they are used together frequently. This is just
19 // a convenience class.
20 class VTKRENDERINGOPENGL2_EXPORT vtkOpenGLHelper
21 {
22 public:
23 vtkShaderProgram* Program;
24 vtkTimeStamp ShaderSourceTime;
25 vtkOpenGLVertexArrayObject* VAO;
26 vtkTimeStamp AttributeUpdateTime;
27 int PrimitiveType;
28 unsigned int ShaderChangeValue;
29
30 vtkOpenGLIndexBufferObject* IBO;
31
32 vtkOpenGLHelper();
33 ~vtkOpenGLHelper();
34 void ReleaseGraphicsResources(vtkWindow* win);
35
36 private:
37 vtkOpenGLHelper(const vtkOpenGLHelper&) = delete;
38 vtkOpenGLHelper& operator=(const vtkOpenGLHelper&) = delete;
39 };
40
41 VTK_ABI_NAMESPACE_END
42 #endif // vtkOpenGLHelper_h
43
44 // VTK-HeaderTest-Exclude: vtkOpenGLHelper.h
vtkOpenGLHelper
Definition: vtkOpenGLHelper.h:21
vtkOpenGLHelper::ShaderChangeValue
unsigned int ShaderChangeValue
Definition: vtkOpenGLHelper.h:28
vtkOpenGLHelper::IBO
vtkOpenGLIndexBufferObject * IBO
Definition: vtkOpenGLHelper.h:30
vtkOpenGLHelper::~vtkOpenGLHelper
~vtkOpenGLHelper()
vtkOpenGLHelper::PrimitiveType
int PrimitiveType
Definition: vtkOpenGLHelper.h:27
vtkOpenGLHelper::AttributeUpdateTime
vtkTimeStamp AttributeUpdateTime
Definition: vtkOpenGLHelper.h:26
vtkOpenGLHelper::vtkOpenGLHelper
vtkOpenGLHelper()
vtkOpenGLHelper::ShaderSourceTime
vtkTimeStamp ShaderSourceTime
Definition: vtkOpenGLHelper.h:24
vtkOpenGLHelper::ReleaseGraphicsResources
void ReleaseGraphicsResources(vtkWindow *win)
vtkOpenGLHelper::VAO
vtkOpenGLVertexArrayObject * VAO
Definition: vtkOpenGLHelper.h:25
vtkOpenGLHelper::Program
vtkShaderProgram * Program
Definition: vtkOpenGLHelper.h:23
vtkOpenGLIndexBufferObject
OpenGL vertex buffer object.
Definition: vtkOpenGLIndexBufferObject.h:18
vtkOpenGLShaderCache
manage Shader Programs within a context
Definition: vtkOpenGLShaderCache.h:25
vtkOpenGLVertexArrayObject
The VertexArrayObject class uses, or emulates, vertex array objects.
Definition: vtkOpenGLVertexArrayObject.h:27
vtkShaderProgram
The ShaderProgram uses one or more Shader objects.
Definition: vtkShaderProgram.h:47
vtkTimeStamp
record modification and/or execution time
Definition: vtkTimeStamp.h:34
vtkWindow
window superclass for vtkRenderWindow
Definition: vtkWindow.h:37
vtkTimeStamp.h