VTK  9.3.1
vtkOpenGLMoleculeMapper.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
14 #ifndef vtkOpenGLMoleculeMapper_h
15 #define vtkOpenGLMoleculeMapper_h
16 
17 #include "vtkDomainsChemistryOpenGL2Module.h" // For export macro
18 #include "vtkMoleculeMapper.h"
19 #include "vtkNew.h" // For vtkNew
20 
21 VTK_ABI_NAMESPACE_BEGIN
24 
25 class VTKDOMAINSCHEMISTRYOPENGL2_EXPORT vtkOpenGLMoleculeMapper : public vtkMoleculeMapper
26 {
27 public:
28  static vtkOpenGLMoleculeMapper* New();
30  void PrintSelf(ostream& os, vtkIndent indent) override;
31 
33 
36  void Render(vtkRenderer*, vtkActor*) override;
37  void ReleaseGraphicsResources(vtkWindow*) override;
39 
43  vtkOpenGLSphereMapper* GetFastAtomMapper() { return this->FastAtomMapper; }
49  vtkHardwareSelector* sel, std::vector<unsigned int>& pixeloffsets, vtkProp* prop) override;
50 
55  void SetMapScalars(bool map) override;
56 
57 protected:
59  ~vtkOpenGLMoleculeMapper() override;
60 
61  void UpdateAtomGlyphPolyData() override;
62  void UpdateBondGlyphPolyData() override;
63 
65 
71 
72 private:
74  void operator=(const vtkOpenGLMoleculeMapper&) = delete;
75 };
76 
77 VTK_ABI_NAMESPACE_END
78 #endif
abstract superclass for all actors, volumes and annotations
Definition: vtkProp.h:45
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:40
vtkOpenGLSphereMapper * GetFastAtomMapper()
provide access to the underlying mappers
virtual void UpdateBondGlyphPolyData()
Cached variables and update methods.
use imposters to draw cylinders
abstract specification for renderers
Definition: vtkRenderer.h:61
virtual void ProcessSelectorPixelBuffers(vtkHardwareSelector *, std::vector< unsigned int > &, vtkProp *)
allows a mapper to update a selections color buffers Called from a prop which in turn is called from ...
Definition: vtkMapper.h:466
vtkNew< vtkOpenGLSphereMapper > FastAtomMapper
Internal mappers.
void Render(vtkRenderer *, vtkActor *) override
Reimplemented from base class.
Mapper that draws vtkMolecule objects.
window superclass for vtkRenderWindow
Definition: vtkWindow.h:27
a simple class to control print indentation
Definition: vtkIndent.h:28
vtkNew< vtkOpenGLStickMapper > FastBondMapper
Internal mappers.
virtual void UpdateAtomGlyphPolyData()
Cached variables and update methods.
draw spheres using imposters
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
void ReleaseGraphicsResources(vtkWindow *) override
Reimplemented from base class.
An accelerated class for rendering molecules.
virtual void SetMapScalars(bool map)
Helper method to set ScalarMode on both AtomGlyphMapper and BondGlyphMapper.
static vtkMoleculeMapper * New()