VTK  9.1.0
vtkSimpleMotionBlurPass.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkSimpleMotionBlurPass.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=========================================================================*/
38#ifndef vtkSimpleMotionBlurPass_h
39#define vtkSimpleMotionBlurPass_h
40
42#include "vtkRenderingOpenGL2Module.h" // For export macro
43
45class vtkOpenGLHelper;
48
49class VTKRENDERINGOPENGL2_EXPORT vtkSimpleMotionBlurPass : public vtkDepthImageProcessingPass
50{
51public:
54 void PrintSelf(ostream& os, vtkIndent indent) override;
55
60 void Render(const vtkRenderState* s) override;
61
68
70
78 vtkGetMacro(SubFrames, int);
79 virtual void SetSubFrames(int subFrames);
81
86 vtkSetMacro(DepthFormat, int);
87
94 vtkSetMacro(ColorFormat, int);
95
96 // Get the depth texture object
97 vtkGetObjectMacro(DepthTexture, vtkTextureObject);
98
99 // Get the Color texture object
100 vtkGetObjectMacro(ColorTexture, vtkTextureObject);
101
102protected:
107
112
117 vtkTextureObject* ColorTexture; // render target for the scene
118 vtkTextureObject* AccumulationTexture[2]; // where we add the colors
119 vtkTextureObject* DepthTexture; // render target for the depth
120
122
130
133
134 int SubFrames; // number of sub frames
135 int CurrentSubFrame; // what one are we on
138
139private:
141 void operator=(const vtkSimpleMotionBlurPass&) = delete;
142};
143
144#endif
Convenient class for post-processing passes.
a simple class to control print indentation
Definition: vtkIndent.h:43
Internal class which encapsulates OpenGL FramebufferObject.
OpenGL rendering window.
Context in which a vtkRenderPass will render.
Avergae frames to simulate motion blur.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
int ViewportWidth
Cache viewport values for depth peeling.
void Render(const vtkRenderState *s) override
Perform rendering according to a render state s.
int ViewportY
Cache viewport values for depth peeling.
virtual void SetSubFrames(int subFrames)
Set the number of sub frames for doing motion blur.
int ViewportX
Cache viewport values for depth peeling.
void ReleaseGraphicsResources(vtkWindow *w) override
Release graphics resources and ask components to release their own resources.
int ViewportHeight
Cache viewport values for depth peeling.
vtkOpenGLFramebufferObject * FrameBufferObject
Graphics resources.
vtkSimpleMotionBlurPass()
Default constructor.
~vtkSimpleMotionBlurPass() override
Destructor.
static vtkSimpleMotionBlurPass * New()
abstracts an OpenGL texture object.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:45