VTK
vtkVRMLExporter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkVRMLExporter.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 =========================================================================*/
30 #ifndef vtkVRMLExporter_h
31 #define vtkVRMLExporter_h
32 
33 #include "vtkIOExportModule.h" // For export macro
34 #include "vtkExporter.h"
35 
36 class vtkLight;
37 class vtkActor;
38 class vtkPoints;
39 class vtkDataArray;
41 class vtkPolyData;
42 class vtkPointData;
43 
44 class VTKIOEXPORT_EXPORT vtkVRMLExporter : public vtkExporter
45 {
46 public:
47  static vtkVRMLExporter *New();
49  void PrintSelf(ostream& os, vtkIndent indent);
50 
52 
55  vtkSetStringMacro(FileName);
56  vtkGetStringMacro(FileName);
58 
60 
63  vtkSetMacro(Speed,double);
64  vtkGetMacro(Speed,double);
66 
71  void SetFilePointer(FILE *);
72 
73 protected:
75  ~vtkVRMLExporter();
76 
77  void WriteData();
78  void WriteALight(vtkLight *aLight, FILE *fp);
79  void WriteAnActor(vtkActor *anActor, FILE *fp);
80  void WritePointData(vtkPoints *points, vtkDataArray *normals,
81  vtkDataArray *tcoords, vtkUnsignedCharArray *colors,
82  FILE *fp);
83  void WriteShapeBegin(vtkActor* actor, FILE *fileP,
84  vtkPolyData *polyData,vtkPointData *pntData,
86  void WriteShapeEnd( FILE *fileP );
87  char *FileName;
88  FILE *FilePointer;
89  double Speed;
90 private:
91  vtkVRMLExporter(const vtkVRMLExporter&) VTK_DELETE_FUNCTION;
92  void operator=(const vtkVRMLExporter&) VTK_DELETE_FUNCTION;
93 };
94 
95 #endif
96 
abstract class to write a scene to a file
Definition: vtkExporter.h:46
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:51
represent and manipulate point attribute data
Definition: vtkPointData.h:37
virtual void WriteData()=0
concrete dataset represents vertices, lines, polygons, and triangle strips
Definition: vtkPolyData.h:85
a simple class to control print indentation
Definition: vtkIndent.h:39
a virtual light for 3D rendering
Definition: vtkLight.h:61
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:54
vtkGetStringMacro(ExtensionsString)
Returns a string listing all available extensions.
vtkSetMacro(IgnoreDriverBugs, bool)
When set known driver bugs are ignored during driver feature detection.
dynamic, self-adjusting array of unsigned char
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
export a scene into VRML 2.0 format.
represent and manipulate 3D points
Definition: vtkPoints.h:39