VTK
vtkX3DExporter.h
Go to the documentation of this file.
1/*=========================================================================
2
3 Program: Visualization Toolkit
4 Module: vtkX3DExporter.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 vtkX3DExporter_h
31#define vtkX3DExporter_h
32
33#include "vtkIOExportModule.h" // For export macro
34#include "vtkExporter.h"
35
36class vtkLight;
37class vtkActor;
38class vtkActor2D;
39class vtkPoints;
40class vtkDataArray;
43class vtkRenderer;
44
45class VTKIOEXPORT_EXPORT vtkX3DExporter : public vtkExporter
46{
47public:
50 void PrintSelf(ostream& os, vtkIndent indent);
51
53
56 vtkSetStringMacro(FileName);
59
61
64 vtkSetMacro(Speed,double);
65 vtkGetMacro(Speed,double);
67
69
72 vtkSetClampMacro(Binary, int, 0, 1);
73 vtkBooleanMacro(Binary, int);
74 vtkGetMacro(Binary, int);
76
78
81 vtkSetClampMacro(Fastest, int, 0, 1);
82 vtkBooleanMacro(Fastest, int);
83 vtkGetMacro(Fastest, int);
85
87
90 vtkSetMacro(WriteToOutputString,int);
91 vtkGetMacro(WriteToOutputString,int);
92 vtkBooleanMacro(WriteToOutputString,int);
94
96
101 vtkGetMacro(OutputStringLength, int);
102 vtkGetStringMacro(OutputString);
103 unsigned char *GetBinaryOutputString()
104 {
105 return reinterpret_cast<unsigned char *>(this->OutputString);
106 }
108
115
116protected:
119
120 // Stream management
124
128 void WriteData();
129
132 int index);
134 vtkDataArray *tcoords, vtkUnsignedCharArray *colors,
135 vtkX3DExporterWriter* writer, int index);
136 void WriteATextActor2D(vtkActor2D *anTextActor2D,
137 vtkX3DExporterWriter* writer);
139 void WriteAnAppearance(vtkActor *anActor, bool writeEmissiveColor, vtkX3DExporterWriter* writer);
141 char *FileName;
142 double Speed;
145
146private:
147
148 vtkX3DExporter(const vtkX3DExporter&) VTK_DELETE_FUNCTION;
149 void operator=(const vtkX3DExporter&) VTK_DELETE_FUNCTION;
150};
151
152
153#endif
a actor that draws 2D data
Definition: vtkActor2D.h:46
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:52
abstract superclass for arrays of numeric data
Definition: vtkDataArray.h:55
abstract class to write a scene to a file
Definition: vtkExporter.h:47
a simple class to control print indentation
Definition: vtkIndent.h:40
a virtual light for 3D rendering
Definition: vtkLight.h:62
represent and manipulate 3D points
Definition: vtkPoints.h:40
abstract specification for renderers
Definition: vtkRenderer.h:64
dynamic, self-adjusting array of unsigned char
X3D Exporter Writer.
create an x3d file
int HasHeadLight(vtkRenderer *ren)
void PrintSelf(ostream &os, vtkIndent indent)
Methods invoked by print to print information about the object including superclasses.
void WriteData()
Write data to output.
unsigned char * GetBinaryOutputString()
char * RegisterAndGetOutputString()
This convenience method returns the string, sets the IVAR to NULL, so that the user is responsible fo...
void WriteALight(vtkLight *aLight, vtkX3DExporterWriter *writer)
void WriteATexture(vtkActor *anActor, vtkX3DExporterWriter *writer)
void WriteAnAppearance(vtkActor *anActor, bool writeEmissiveColor, vtkX3DExporterWriter *writer)
void WriteAnActor(vtkActor *anActor, vtkX3DExporterWriter *writer, int index)
static vtkX3DExporter * New()
void WriteATextActor2D(vtkActor2D *anTextActor2D, vtkX3DExporterWriter *writer)
void WritePointData(vtkPoints *points, vtkDataArray *normals, vtkDataArray *tcoords, vtkUnsignedCharArray *colors, vtkX3DExporterWriter *writer, int index)
@ points
Definition: vtkX3D.h:446
@ index
Definition: vtkX3D.h:246
vtkSetMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkBooleanMacro(IgnoreDriverBugs, bool)
Updates the extensions string.
vtkGetStringMacro(ExtensionsString)
Returns a string listing all available extensions.