VTK  9.7.1
vtkEquirectangularToCubeMapTexture.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
17 #ifndef vtkEquirectangularToCubeMapTexture_h
18 #define vtkEquirectangularToCubeMapTexture_h
19 
20 #include "vtkOpenGLTexture.h"
21 #include "vtkRenderingOpenGL2Module.h" // For export macro
22 #include "vtkWrappingHints.h" // For VTK_MARSHALAUTO
23 
24 VTK_ABI_NAMESPACE_BEGIN
27 class vtkOpenGLTexture;
28 class vtkRenderWindow;
29 
30 class VTKRENDERINGOPENGL2_EXPORT VTK_MARSHALAUTO vtkEquirectangularToCubeMapTexture
31  : public vtkOpenGLTexture
32 {
33 public:
36  void PrintSelf(ostream& os, vtkIndent indent) override;
37 
39 
42  void SetInputTexture(vtkOpenGLTexture* texture);
43  vtkGetObjectMacro(InputTexture, vtkOpenGLTexture);
45 
49  void Load(vtkRenderer*) override;
50 
54  void Render(vtkRenderer* ren) override { this->Load(ren); }
55 
57 
61  vtkGetMacro(CubeMapSize, unsigned int);
62  vtkSetMacro(CubeMapSize, unsigned int);
64 
71  void ReleaseGraphicsResources(vtkWindow*) override;
72 
73 protected:
76 
77  unsigned int CubeMapSize = 512;
78  vtkOpenGLTexture* InputTexture = nullptr;
79 
80 private:
82  void operator=(const vtkEquirectangularToCubeMapTexture&) = delete;
83 };
84 
85 VTK_ABI_NAMESPACE_END
86 #endif
OpenGL rendering window.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
abstract specification for renderers
Definition: vtkRenderer.h:63
void Load(vtkRenderer *) override
Implement base class method.
OpenGL texture map.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:41
a simple class to control print indentation
Definition: vtkIndent.h:28
void Render(vtkRenderer *ren) override
Implement base class method.
compute a cubemap texture based on a standard equirectangular projection
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this texture.
Internal class which encapsulates OpenGL FramebufferObject.
create a window for renderers to draw into
#define VTK_MARSHALAUTO
static vtkOpenGLTexture * New()