VTK  9.3.20240328
vtkLODActor.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
126 #ifndef vtkLODActor_h
127 #define vtkLODActor_h
128 
129 #include "vtkActor.h"
130 #include "vtkRenderingLODModule.h" // For export macro
131 
132 VTK_ABI_NAMESPACE_BEGIN
133 class vtkMapper;
134 class vtkMapperCollection;
136 class vtkPolyDataMapper;
137 class vtkRenderer;
138 class vtkViewport;
139 class vtkWindow;
140 
141 class VTKRENDERINGLOD_EXPORT vtkLODActor : public vtkActor
142 {
143 public:
144  vtkTypeMacro(vtkLODActor, vtkActor);
145  void PrintSelf(ostream& os, vtkIndent indent) override;
146 
152  static vtkLODActor* New();
153 
158  void Render(vtkRenderer*, vtkMapper*) override;
159 
166 
171  void AddLODMapper(vtkMapper* mapper);
172 
174 
181  vtkGetObjectMacro(LowResFilter, vtkPolyDataAlgorithm);
182  vtkGetObjectMacro(MediumResFilter, vtkPolyDataAlgorithm);
184 
186 
189  vtkGetMacro(NumberOfCloudPoints, int);
190  vtkSetMacro(NumberOfCloudPoints, int);
192 
194 
198  vtkGetObjectMacro(LODMappers, vtkMapperCollection);
200 
204  void Modified() override;
205 
209  void ShallowCopy(vtkProp* prop) override;
210 
211 protected:
213  ~vtkLODActor() override;
214 
217 
218  // We can create our own LOD filters. The default is to use a
219  //
224 
227 
228  virtual void CreateOwnLODs();
229  virtual void UpdateOwnLODs();
230  virtual void DeleteOwnLODs();
231 
232 private:
233  vtkLODActor(const vtkLODActor&) = delete;
234  void operator=(const vtkLODActor&) = delete;
235 };
236 
237 VTK_ABI_NAMESPACE_END
238 #endif
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:150
a simple class to control print indentation
Definition: vtkIndent.h:108
an actor that supports multiple levels of detail
Definition: vtkLODActor.h:142
static vtkLODActor * New()
Creates a vtkLODActor with the following defaults: origin(0,0,0) position=(0,0,0) scale=(1,...
virtual void SetMediumResFilter(vtkPolyDataAlgorithm *)
You may plug in your own filters to decimate/subsample the input.
void Render(vtkRenderer *, vtkMapper *) override
This causes the actor to be rendered.
virtual void DeleteOwnLODs()
virtual void UpdateOwnLODs()
void ReleaseGraphicsResources(vtkWindow *) override
Release any graphics resources that are being consumed by this actor.
~vtkLODActor() override
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ShallowCopy(vtkProp *prop) override
Shallow copy of an LOD actor.
vtkPolyDataMapper * MediumMapper
Definition: vtkLODActor.h:223
vtkTimeStamp BuildTime
Definition: vtkLODActor.h:225
vtkActor * Device
Definition: vtkLODActor.h:215
vtkMapperCollection * LODMappers
Definition: vtkLODActor.h:216
vtkPolyDataAlgorithm * MediumResFilter
Definition: vtkLODActor.h:221
void AddLODMapper(vtkMapper *mapper)
Add another level of detail.
vtkPolyDataAlgorithm * LowResFilter
Definition: vtkLODActor.h:220
vtkPolyDataMapper * LowMapper
Definition: vtkLODActor.h:222
int NumberOfCloudPoints
Definition: vtkLODActor.h:226
void Modified() override
When this objects gets modified, this method also modifies the object.
virtual void SetLowResFilter(vtkPolyDataAlgorithm *)
You may plug in your own filters to decimate/subsample the input.
virtual void CreateOwnLODs()
an ordered list of mappers
abstract class specifies interface to map data to graphics primitives
Definition: vtkMapper.h:136
Superclass for algorithms that produce only polydata as output.
map vtkPolyData to graphics primitives
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:65
abstract specification for renderers
Definition: vtkRenderer.h:171
record modification and/or execution time
Definition: vtkTimeStamp.h:44
abstract specification for Viewports
Definition: vtkViewport.h:64
window superclass for vtkRenderWindow
Definition: vtkWindow.h:47