3 #ifndef vtkOBJImporterInternals_h
4 #define vtkOBJImporterInternals_h
6 #include "vtkIOImportModule.h"
12 VTK_ABI_NAMESPACE_BEGIN
24 double map_Kd_scale[3];
25 double map_Kd_offset[3];
40 struct vtkOBJImportedPolyDataWithMaterial;
58 if (this->FileName == arg)
71 if (this->MTLFileName == arg)
76 this->DefaultMTLFileName =
false;
80 this->TextureStreams = streamMap;
85 if (this->TexturePath.empty())
90 const char sep =
'\\';
94 if (this->TexturePath.at(this->TexturePath.size() - 1) != sep)
96 this->TexturePath += sep;
98 this->DefaultTexturePath =
false;
103 return this->TextureStreams;
110 vtkSetMacro(VertexScale,
double);
111 vtkGetMacro(VertexScale,
double);
112 vtkGetMacro(SuccessParsingFiles,
int);
116 int GetNumberOfOutputs();
128 std::vector<vtkOBJImportedPolyDataWithMaterial*>
poly_list;
136 std::vector<vtkOBJImportedMaterial*> ParseOBJandMTL(
139 void ReadVertices(
bool gotFirstUseMaterialTag,
char* pLine,
float xyz,
int lineNr,
double v_scale,
148 vtkSetMacro(SuccessParsingFiles,
int);
153 bool DefaultMTLFileName;
157 bool DefaultTexturePath;
161 int SuccessParsingFiles;
174 VTK_ABI_NAMESPACE_END
void SetMTLfileName(const char *arg)
represents an object (geometry & properties) in a rendered scene
Abstract class used for custom streams.
void SetMTLStream(vtkResourceStream *mtlStream)
void SetStream(vtkResourceStream *stream)
virtual int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector)
This is called by the superclass.
const std::map< std::string, vtkResourceStream * > & GetTextureStreams() const
std::string texture_filename
std::vector< vtkOBJImportedPolyDataWithMaterial * > poly_list
const char * GetClassName()
abstract specification for renderers
concrete dataset represents vertices, lines, polygons, and triangle strips
const std::string & GetMTLFileName() const
const std::string & GetFileName() const
static vtkPolyDataAlgorithm * New()
Superclass for algorithms that produce only polydata as output.
void SetFileName(const char *arg)
a simple class to control print indentation
std::map< std::string, vtkOBJImportedMaterial * > mtlName_to_mtlData
VTKIOIMPORT_EXPORT void obj_set_material_defaults(vtkOBJImportedMaterial *mtl)
std::vector< vtkOBJImportedMaterial * > parsedMTLs
an ordered list of actors
std::vector< vtkSmartPointer< vtkActor > > actor_list
void SetTextureStreams(std::map< std::string, vtkResourceStream * > streamMap)
create a window for renderers to draw into
const std::string & GetTexturePath() const
void SetTexturePath(const char *arg)
std::vector< vtkSmartPointer< vtkPolyData > > outVector_of_vtkPolyData
vtkPolyData * GetOutput()
Get the output data object for a port on this algorithm.
represent and manipulate 3D points
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
VTKIOIMPORT_EXPORT bool bindTexturedPolydataToRenderWindow(vtkRenderWindow *renderWindow, vtkRenderer *renderer, vtkOBJPolyDataProcessor *reader, vtkActorCollection *actorCollection)