VTK
vtkContextDevice3D.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkContextDevice3D.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
15 
27 #ifndef vtkContextDevice3D_h
28 #define vtkContextDevice3D_h
29 
30 #include "vtkRenderingContext2DModule.h" // For export macro
31 #include "vtkObject.h"
32 #include "vtkVector.h" // For the vector coordinates.
33 #include "vtkRect.h" // For the rectangles..
34 
35 class vtkMatrix4x4;
36 class vtkViewport;
37 class vtkPen;
38 class vtkBrush;
39 
41 {
42 public:
44  virtual void PrintSelf(ostream &os, vtkIndent indent);
45 
46  static vtkContextDevice3D * New();
47 
49 
50  virtual void DrawPoly(const float *verts, int n,
51  const unsigned char *colors = 0, int nc = 0) = 0;
53 
55 
56  virtual void DrawLines(const float *verts, int n,
57  const unsigned char *colors = 0, int nc = 0) = 0;
59 
61 
62  virtual void DrawPoints(const float *verts, int n,
63  const unsigned char *colors = 0, int nc = 0) = 0;
65 
67 
68  virtual void DrawTriangleMesh(const float *mesh, int n,
69  const unsigned char *colors, int nc) = 0;
71 
76  virtual void ApplyPen(vtkPen *pen) = 0;
77 
82  virtual void ApplyBrush(vtkBrush *brush) = 0;
83 
85  virtual void SetMatrix(vtkMatrix4x4 *m) = 0;
86 
88  virtual void GetMatrix(vtkMatrix4x4 *m) = 0;
89 
91  virtual void MultiplyMatrix(vtkMatrix4x4 *m) = 0;
92 
94  virtual void PushMatrix() = 0;
95 
97  virtual void PopMatrix() = 0;
98 
101  virtual void SetClipping(const vtkRecti &rect) = 0;
102 
105  virtual void DisableClipping() { this->EnableClipping(false); }
106 
108  virtual void EnableClipping(bool enable) = 0;
109 
111 
112  virtual void EnableClippingPlane(int i, double *planeEquation) = 0;
113  virtual void DisableClippingPlane(int i) = 0;
115 
116 protected:
119 
120 private:
121  vtkContextDevice3D(const vtkContextDevice3D &); // Not implemented.
122  void operator=(const vtkContextDevice3D &); // Not implemented.
123 };
124 
125 #endif
vtkContextDevice3D::DrawPoints
virtual void DrawPoints(const float *verts, int n, const unsigned char *colors=0, int nc=0)=0
vtkBrush
provides a brush that fills shapes drawn by vtkContext2D.
Definition: vtkBrush.h:37
vtkContextDevice3D::New
static vtkContextDevice3D * New()
vtkContextDevice3D::DrawLines
virtual void DrawLines(const float *verts, int n, const unsigned char *colors=0, int nc=0)=0
vtkgl::m
const GLfloat * m
Definition: vtkgl.h:18169
vtkContextDevice3D::ApplyBrush
virtual void ApplyBrush(vtkBrush *brush)=0
VTKRENDERINGCONTEXT2D_EXPORT
#define VTKRENDERINGCONTEXT2D_EXPORT
Definition: vtkRenderingContext2DModule.h:15
vtkContextDevice3D::SetClipping
virtual void SetClipping(const vtkRecti &rect)=0
vtkTypeMacro
#define vtkTypeMacro(thisClass, superclass)
Definition: vtkSetGet.h:642
vtkContextDevice3D
Abstract class for drawing 3D primitives.
Definition: vtkContextDevice3D.h:41
vtkgl::n
GLclampd n
Definition: vtkgl.h:14370
vtkObject
abstract base class for most VTK objects
Definition: vtkObject.h:62
vtkVector.h
vtkContextDevice3D::~vtkContextDevice3D
~vtkContextDevice3D()
vtkgl::enable
GLboolean enable
Definition: vtkgl.h:18647
vtkContextDevice3D::PrintSelf
virtual void PrintSelf(ostream &os, vtkIndent indent)
vtkContextDevice3D::PushMatrix
virtual void PushMatrix()=0
vtkContextDevice3D::DrawPoly
virtual void DrawPoly(const float *verts, int n, const unsigned char *colors=0, int nc=0)=0
vtkContextDevice3D::EnableClippingPlane
virtual void EnableClippingPlane(int i, double *planeEquation)=0
vtkContextDevice3D::vtkContextDevice3D
vtkContextDevice3D()
vtkRect.h
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:39
vtkMatrix4x4
represent and manipulate 4x4 transformation matrices
Definition: vtkMatrix4x4.h:39
vtkContextDevice3D::DrawTriangleMesh
virtual void DrawTriangleMesh(const float *mesh, int n, const unsigned char *colors, int nc)=0
vtkContextDevice3D::SetMatrix
virtual void SetMatrix(vtkMatrix4x4 *m)=0
vtkContextDevice3D::MultiplyMatrix
virtual void MultiplyMatrix(vtkMatrix4x4 *m)=0
vtkViewport
abstract specification for Viewports
Definition: vtkViewport.h:47
vtkObject.h
vtkContextDevice3D::GetMatrix
virtual void GetMatrix(vtkMatrix4x4 *m)=0
vtkContextDevice3D::ApplyPen
virtual void ApplyPen(vtkPen *pen)=0
vtkContextDevice3D::EnableClipping
virtual void EnableClipping(bool enable)=0
vtkContextDevice3D::DisableClipping
virtual void DisableClipping()
Definition: vtkContextDevice3D.h:105
vtkRecti
Definition: vtkRect.h:88
vtkContextDevice3D::PopMatrix
virtual void PopMatrix()=0
vtkPen
provides a pen that draws the outlines of shapes drawn by vtkContext2D.
Definition: vtkPen.h:39
vtkRenderingContext2DModule.h
vtkContextDevice3D::DisableClippingPlane
virtual void DisableClippingPlane(int i)=0