VTK
9.3.1
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
IO
Export
vtkOBJExporter.h
Go to the documentation of this file.
1
// SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2
// SPDX-License-Identifier: BSD-3-Clause
19
#ifndef vtkOBJExporter_h
20
#define vtkOBJExporter_h
21
22
#include "
vtkExporter.h
"
23
#include "vtkIOExportModule.h"
// For export macro
24
#include <fstream>
// For ofstream
25
#include <map>
// For map
26
#include <vector>
// For string
27
28
VTK_ABI_NAMESPACE_BEGIN
29
class
vtkActor
;
30
class
vtkTexture
;
31
32
class
VTKIOEXPORT_EXPORT
vtkOBJExporter
:
public
vtkExporter
33
{
34
public
:
35
static
vtkOBJExporter
*
New
();
36
vtkTypeMacro(
vtkOBJExporter
,
vtkExporter
);
37
void
PrintSelf
(ostream& os,
vtkIndent
indent)
override
;
38
40
44
vtkSetFilePathMacro(FilePrefix);
45
vtkGetFilePathMacro(FilePrefix);
47
49
52
vtkSetStringMacro(OBJFileComment);
53
vtkGetStringMacro(OBJFileComment);
55
57
60
vtkSetStringMacro(MTLFileComment);
61
vtkGetStringMacro(MTLFileComment);
63
64
protected
:
65
vtkOBJExporter
();
66
~
vtkOBJExporter
()
override
;
67
68
void
WriteData
()
override
;
69
void
WriteAnActor(
70
vtkActor
* anActor, std::ostream& fpObj, std::ostream& fpMat,
std::string
& modelName,
int
&
id
);
71
char
*
FilePrefix
;
72
char
*
OBJFileComment
;
73
char
*
MTLFileComment
;
74
bool
FlipTexture
;
75
std::map<std::string, vtkTexture*>
TextureFileMap
;
76
77
private
:
78
vtkOBJExporter
(
const
vtkOBJExporter
&) =
delete
;
79
void
operator=(
const
vtkOBJExporter
&) =
delete
;
80
};
81
82
VTK_ABI_NAMESPACE_END
83
#endif
vtkExporter
abstract class to write a scene to a file
Definition:
vtkExporter.h:36
vtkActor
represents an object (geometry & properties) in a rendered scene
Definition:
vtkActor.h:40
vtkExporter::WriteData
virtual void WriteData()=0
vtkOBJExporter::FlipTexture
bool FlipTexture
Definition:
vtkOBJExporter.h:74
vtkX3D::string
Definition:
vtkX3D.h:490
vtkOBJExporter::OBJFileComment
char * OBJFileComment
Definition:
vtkOBJExporter.h:72
vtkIndent
a simple class to control print indentation
Definition:
vtkIndent.h:28
vtkTexture
handles properties associated with a texture map
Definition:
vtkTexture.h:57
vtkExporter::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkExporter.h
vtkOBJExporter::MTLFileComment
char * MTLFileComment
Definition:
vtkOBJExporter.h:73
vtkOBJExporter::TextureFileMap
std::map< std::string, vtkTexture * > TextureFileMap
Definition:
vtkOBJExporter.h:75
vtkObject::New
static vtkObject * New()
Create an object with Debug turned off, modified time initialized to zero, and reference counting on...
vtkOBJExporter::FilePrefix
char * FilePrefix
Definition:
vtkOBJExporter.h:71
vtkOBJExporter
export a scene into Wavefront format.
Definition:
vtkOBJExporter.h:32
Generated on Sun Mar 23 2025 01:24:26 for VTK by
1.8.10