VTK
vtkOBJExporter.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkOBJExporter.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 =========================================================================*/
28 #ifndef vtkOBJExporter_h
29 #define vtkOBJExporter_h
30 
31 #include "vtkIOExportModule.h" // For export macro
32 #include "vtkExporter.h"
33 
34 class vtkActor;
35 
36 class VTKIOEXPORT_EXPORT vtkOBJExporter : public vtkExporter
37 {
38 public:
39  static vtkOBJExporter *New();
40  vtkTypeMacro(vtkOBJExporter,vtkExporter);
41  void PrintSelf(ostream& os, vtkIndent indent) override;
42 
44 
48  vtkSetStringMacro(FilePrefix);
49  vtkGetStringMacro(FilePrefix);
51 
53 
56  vtkSetStringMacro(OBJFileComment);
57  vtkGetStringMacro(OBJFileComment);
59 
61 
64  vtkSetStringMacro(MTLFileComment);
65  vtkGetStringMacro(MTLFileComment);
67 
68 protected:
70  ~vtkOBJExporter() override;
71 
72  void WriteData() override;
73  void WriteAnActor(vtkActor *anActor, FILE *fpObj, FILE *fpMat, int &id);
74  char *FilePrefix;
77 private:
78  vtkOBJExporter(const vtkOBJExporter&) = delete;
79  void operator=(const vtkOBJExporter&) = delete;
80 };
81 
82 #endif
83 
vtkObject::New
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on.
vtkOBJExporter::OBJFileComment
char * OBJFileComment
Definition: vtkOBJExporter.h:75
vtkExporter::WriteData
virtual void WriteData()=0
vtkOBJExporter
export a scene into Wavefront format.
Definition: vtkOBJExporter.h:36
vtkActor
represents an object (geometry & properties) in a rendered scene
Definition: vtkActor.h:45
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:33
vtkExporter::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkExporter
abstract class to write a scene to a file
Definition: vtkExporter.h:47
vtkOBJExporter::MTLFileComment
char * MTLFileComment
Definition: vtkOBJExporter.h:76
vtkExporter.h
vtkOBJExporter::FilePrefix
char * FilePrefix
Definition: vtkOBJExporter.h:74