VTK: Rendering/Core/vtkBackgroundColorMonitor.h Source File

| VTK 9.3.1

vtkBackgroundColorMonitor.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
20 #ifndef vtkBackgroundColorMonitor_h
21 #define vtkBackgroundColorMonitor_h
22
23 #include "vtkObject.h"
24 #include "vtkRenderingCoreModule.h" // for export macro
25
26 VTK_ABI_NAMESPACE_BEGIN
27 class vtkRenderer;
28
29 class VTKRENDERINGCORE_EXPORT vtkBackgroundColorMonitor : public vtkObject
30 {
31 public:
32 static vtkBackgroundColorMonitor* New();
33 vtkTypeMacro(vtkBackgroundColorMonitor, vtkObject);
34 void PrintSelf(ostream& os, vtkIndent indent) override;
35
43 bool StateChanged(vtkRenderer* ren);
44
49 void Update(vtkRenderer* ren);
50
51 protected:
52 vtkBackgroundColorMonitor();
53 ~vtkBackgroundColorMonitor() override = default;
54
55 private:
56 unsigned int UpTime;
57 bool Gradient;
58 double Color1[3];
59 double Color2[3];
60
61 vtkBackgroundColorMonitor(const vtkBackgroundColorMonitor&) = delete;
62 void operator=(const vtkBackgroundColorMonitor&) = delete;
63 };
64
65 VTK_ABI_NAMESPACE_END
66 #endif
vtkBackgroundColorMonitor
tracks state of background color(s).
Definition: vtkBackgroundColorMonitor.h:30
vtkBackgroundColorMonitor::vtkBackgroundColorMonitor
vtkBackgroundColorMonitor()
vtkBackgroundColorMonitor::StateChanged
bool StateChanged(vtkRenderer *ren)
Fetches the current background color state and updates the internal copies of the data.
vtkBackgroundColorMonitor::~vtkBackgroundColorMonitor
~vtkBackgroundColorMonitor() override=default
vtkBackgroundColorMonitor::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkBackgroundColorMonitor::Update
void Update(vtkRenderer *ren)
Update the internal state if anything changed.
vtkBackgroundColorMonitor::New
static vtkBackgroundColorMonitor * New()
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:38
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:61
vtkRenderer
abstract specification for renderers
Definition: vtkRenderer.h:71
vtkObject.h