#include <model.h>
Public Member Functions | |
Model (std::string filename) | |
std::string | getFilename () |
bool | getIsSTL () |
std::vector< Material > | getMaterials () |
std::vector< Vector3D > | getVertices () |
std::vector< Cell > | getCells () |
int | getMaterialCount () |
int | getVertexCount () |
int | getCellCount () |
std::string | getCellList () |
Vector3D | getCentre () |
void | copyToFile (std::string filename) |
void | saveToFile (std::string filename) |
Model that loads vectors and cells from files.
void Model::copyToFile | ( | std::string | filename | ) |
Copy current model to another file (just copies the contents of the input file)
int Model::getCellCount | ( | ) |
Get total number of cells
std::string Model::getCellList | ( | ) |
Return a string with the total number of cells and, for each cell, its ID and type
std::vector< Cell > Model::getCells | ( | ) |
Get list of cells as a std::vector
Vector3D Model::getCentre | ( | ) |
Get the centre of the model based on the vertices
std::string Model::getFilename | ( | ) |
Get model's filename
bool Model::getIsSTL | ( | ) |
Return true if model is a .STL file
int Model::getMaterialCount | ( | ) |
Get total number of materials
std::vector< Material > Model::getMaterials | ( | ) |
Get list of materials as a std::vector
int Model::getVertexCount | ( | ) |
Get total number of vertices
std::vector< Vector3D > Model::getVertices | ( | ) |
Get list of vertices as a std::vector
void Model::saveToFile | ( | std::string | filename | ) |
Save current model to file