VTK  9.5.20250802
vtkAnariLightNode.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
19#ifndef vtkAnariLightNode_h
20#define vtkAnariLightNode_h
21
22#include "vtkLightNode.h"
23#include "vtkRenderingAnariModule.h" // For export macro
24
25VTK_ABI_NAMESPACE_BEGIN
26
27struct vtkAnariLightNodeInternals;
31class vtkLight;
32
33class VTKRENDERINGANARI_EXPORT vtkAnariLightNode : public vtkLightNode
34{
35public:
38 void PrintSelf(ostream& os, vtkIndent indent) override;
39
43 void Build(bool prepass) override;
47 void Synchronize(bool prepass) override;
51 void Render(bool prepass) override;
52
56 void Invalidate(bool prepass) override;
57
64
66
69 static void SetLightScale(double, vtkLight*);
70 static double GetLightScale(vtkLight*);
72
73 // state beyond rendering core...
74
81
83
86 static void SetRadius(double, vtkLight*);
87 static double GetRadius(vtkLight*);
89
97
99
102 static void SetFalloffAngle(double, vtkLight*);
103 static double GetFalloffAngle(vtkLight*);
105
106protected:
109
110private:
111 vtkAnariLightNode(const vtkAnariLightNode&) = delete;
112 void operator=(const vtkAnariLightNode&) = delete;
113
114 void ClearLight();
115 vtkLight* GetVtkLight() const;
116 bool LightWasModified() const;
117
118 vtkAnariLightNodeInternals* Internals{ nullptr };
119};
120
121VTK_ABI_NAMESPACE_END
122#endif
links vtkLights to ANARI
static void SetLightScale(double, vtkLight *)
Convenience method to set/get LIGHT_SCALE on a vtkLight.
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
static double GetRadius(vtkLight *)
static vtkAnariLightNode * New()
~vtkAnariLightNode() override
void Render(bool prepass) override
Make ANARI calls to render me.
void Invalidate(bool prepass) override
Invalidates cached rendering data.
static void SetRadius(double, vtkLight *)
Convenience method to set/get RADIUS on a vtkLight.
static double GetFalloffAngle(vtkLight *)
static double GetLightScale(vtkLight *)
Convenience method to set/get LIGHT_SCALE on a vtkLight.
static void SetFalloffAngle(double, vtkLight *)
Convenience method to set/get FALLOFF_ANGLE on a vtkLight.
void Synchronize(bool prepass) override
Sync ANARICamera parameters with vtkCamera.
void Build(bool prepass) override
Ensure the right type of ANARICamera object is being held.
links vtkRenderers to ANARI
a simple class to control print indentation
Definition vtkIndent.h:108
Key for double values in vtkInformation.
Key for integer values in vtkInformation.
vtkViewNode specialized for vtkLights
a virtual light for 3D rendering
Definition vtkLight.h:159
static vtkInformationDoubleKey * FALLOFF_ANGLE()
For cone-shaped lights, size (angle in radians) of the region between the rim (of the illumination co...
static vtkInformationDoubleKey * RADIUS()
The radius setting, when > 0.0, produces soft shadows in the path tracer.
static vtkInformationDoubleKey * LIGHT_SCALE()
A global multiplier to all ANARI lights.