|
Colobot
|
Model file reader/writer. More...
#include <modelfile.h>
Public Member Functions | |
| bool | ReadTextModel (const std::string &fileName) |
| Reads a model in text format from file. | |
| bool | ReadTextModel (std::istream &stream) |
| Reads a model in text format from stream. | |
| bool | WriteTextModel (const std::string &fileName) |
| Writes the model in text format to a file. | |
| bool | WriteTextModel (std::ostream &stream) |
| Writes the model in text format to a stream. | |
| bool | ReadBinaryModel (const std::string &fileName) |
| Reads a model in new binary format from file. | |
| bool | ReadBinaryModel (std::istream &stream) |
| Reads a model in new binary format from stream. | |
| bool | WriteBinaryModel (const std::string &fileName) |
| Writes the model in binary format to a file. | |
| bool | WriteBinaryModel (std::ostream &stream) |
| Writes the model in binary format to a stream. | |
| bool | ReadModel (const std::string &fileName) |
| bool | ReadModel (std::istream &stream) |
| bool | WriteModel (const std::string &fileName) |
| bool | WriteModel (std::ostream &stream) |
| int | GetTriangleCount () |
| Returns the number of triangles in model. | |
|
const std::vector < ModelTriangle > & | GetTriangles () |
| Returns the triangle vector. | |
| void | SetPrintDebugInfo (bool printDebugInfo) |
| Controls printing of debug information. | |
Protected Member Functions | |
| LODLevel | MinMaxToLodLevel (float min, float max) |
| void | LODLevelToMinMax (LODLevel lodLevel, float &min, float &max) |
Protected Attributes | |
| std::vector< ModelTriangle > | m_triangles |
| Model triangles. | |
| bool | m_printDebugInfo |
Model file reader/writer.
Allows reading and writing model objects. Models are collections of ModelTriangle structs.
|
protected |
| bool Gfx::CModelFile::ReadModel | ( | const std::string & | fileName | ) |
Reads a binary Colobot model from file
| bool Gfx::CModelFile::ReadModel | ( | std::istream & | stream | ) |
Reads a binary Colobot model from stream
| bool Gfx::CModelFile::WriteModel | ( | const std::string & | fileName | ) |
Writes the model to Colobot binary model file
| bool Gfx::CModelFile::WriteModel | ( | std::ostream & | stream | ) |
Writes the model to Colobot binary model file
1.8.5