VTK
vtkOpenGLStickMapper.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4 
5  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
6  All rights reserved.
7  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
8 
9  This software is distributed WITHOUT ANY WARRANTY; without even
10  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
11  PURPOSE. See the above copyright notice for more information.
12 
13 =========================================================================*/
21 #ifndef vtkOpenGLStickMapper_h
22 #define vtkOpenGLStickMapper_h
23 
24 #include "vtkDomainsChemistryOpenGL2Module.h" // For export macro
25 #include "vtkOpenGLPolyDataMapper.h"
26 
27 class VTKDOMAINSCHEMISTRYOPENGL2_EXPORT vtkOpenGLStickMapper : public vtkOpenGLPolyDataMapper
28 {
29 public:
32  void PrintSelf(ostream& os, vtkIndent indent);
33 
35 
36  vtkSetStringMacro(ScaleArray);
38 
40 
41  vtkSetStringMacro(OrientationArray);
43 
45 
46  vtkSetStringMacro(SelectionIdArray);
48 
49 protected:
52 
54 
55  virtual void GetShaderTemplate(
56  std::map<vtkShader::Type, vtkShader *> shaders,
57  vtkRenderer *ren, vtkActor *act);
59 
61 
62  virtual void ReplaceShaderValues(
63  std::map<vtkShader::Type, vtkShader *> shaders,
64  vtkRenderer *ren, vtkActor *act);
66 
68  virtual void SetCameraShaderParameters(vtkOpenGLHelper &cellBO, vtkRenderer *ren, vtkActor *act);
69 
71  virtual void SetMapperShaderParameters(vtkOpenGLHelper &cellBO, vtkRenderer *ren, vtkActor *act);
72 
73  const char *ScaleArray;
74  const char *OrientationArray;
75  const char *SelectionIdArray;
76 
78  virtual bool GetNeedToRebuildBufferObjects(vtkRenderer *ren, vtkActor *act);
79 
81  virtual void BuildBufferObjects(vtkRenderer *ren, vtkActor *act);
82 
83  virtual void RenderPieceDraw(vtkRenderer *ren, vtkActor *act);
84 
85 private:
86  vtkOpenGLStickMapper(const vtkOpenGLStickMapper&); // Not implemented.
87  void operator=(const vtkOpenGLStickMapper&); // Not implemented.
88 };
89 
90 #endif
vtkOpenGLStickMapper::New
static vtkOpenGLStickMapper * New()
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkgl::shaders
const GLuint * shaders
Definition: vtkgl.h:14179
vtkOpenGLHelper
Definition: vtkOpenGLHelper.h:31
vtkActor
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:51
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkSetStringMacro
#define vtkSetStringMacro(name)
Definition: vtkSetGet.h:104
vtkShader
Vertex or Fragment shader, combined into a ShaderProgram.
Definition: vtkShader.h:37
vtkOpenGLStickMapper
use imposters to draw cylinders
Definition: vtkOpenGLStickMapper.h:28
vtkRenderer
abstract specification for renderers
Definition: vtkRenderer.h:64
vtkgl::void
typedef void(APIENTRYP PFNGLBLENDCOLORPROC)(GLclampf red
vtkOpenGLPolyDataMapper
a PolyDataMapper for the OpenGL library
Definition: vtkOpenGLPolyDataMapper.h:43