VTK  9.3.0
vtkPBRIrradianceTexture.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
24#ifndef vtkPBRIrradianceTexture_h
25#define vtkPBRIrradianceTexture_h
26
27#include "vtkOpenGLTexture.h"
28#include "vtkRenderingOpenGL2Module.h" // For export macro
29
30VTK_ABI_NAMESPACE_BEGIN
34class vtkRenderWindow;
35
36class VTKRENDERINGOPENGL2_EXPORT vtkPBRIrradianceTexture : public vtkOpenGLTexture
37{
38public:
41 void PrintSelf(ostream& os, vtkIndent indent) override;
42
44
48 vtkGetObjectMacro(InputTexture, vtkOpenGLTexture);
50
54 void Load(vtkRenderer*) override;
55
59 void Render(vtkRenderer* ren) override { this->Load(ren); }
60
62
66 vtkGetMacro(IrradianceSize, unsigned int);
67 vtkSetMacro(IrradianceSize, unsigned int);
69
71
77 vtkGetMacro(IrradianceStep, float);
78 vtkSetMacro(IrradianceStep, float);
80
82
87 vtkGetMacro(ConvertToLinear, bool);
88 vtkSetMacro(ConvertToLinear, bool);
89 vtkBooleanMacro(ConvertToLinear, bool);
91
99
100protected:
103
104 float IrradianceStep = 0.04908738521; // pi / 64
105 unsigned int IrradianceSize = 256;
106 vtkOpenGLTexture* InputTexture = nullptr;
107 bool ConvertToLinear = false;
108
109private:
111 void operator=(const vtkPBRIrradianceTexture&) = delete;
112};
113
114VTK_ABI_NAMESPACE_END
115#endif
a simple class to control print indentation
Definition vtkIndent.h:38
Internal class which encapsulates OpenGL FramebufferObject.
OpenGL rendering window.
OpenGL texture map.
void Load(vtkRenderer *) override
Implement base class method.
precompute irradiance texture used in physically based rendering
void Render(vtkRenderer *ren) override
Implement base class method.
vtkPBRIrradianceTexture()=default
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this texture.
void Load(vtkRenderer *) override
Implement base class method.
static vtkPBRIrradianceTexture * New()
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkPBRIrradianceTexture() override
void SetInputTexture(vtkOpenGLTexture *texture)
Get/Set the input texture.
create a window for renderers to draw into
abstract specification for renderers
Definition vtkRenderer.h:68
window superclass for vtkRenderWindow
Definition vtkWindow.h:34