A mesh composed by multiple Surface and an indexes collection of Vertex
|
| static shared_ptr< Mesh > | create (const string &meshName="Mesh") |
| |
| static shared_ptr< Mesh > | create (const vector< Vertex > &vertices, const vector< uint32_t > &indices, const vector< shared_ptr< Surface >> &surfaces, const string &meshName="Mesh") |
| |
| static shared_ptr<Mesh> create |
( |
const string & |
meshName = "Mesh" | ) |
|
|
static |
Creates an empty Mesh
- Parameters
-
| static shared_ptr<Mesh> create |
( |
const vector< Vertex > & |
vertices, |
|
|
const vector< uint32_t > & |
indices, |
|
|
const vector< shared_ptr< Surface >> & |
surfaces, |
|
|
const string & |
meshName = "Mesh" |
|
) |
| |
|
static |
Creates a Mesh from vertices
- Parameters
-
| vertices | Vertices |
| indices | Indexes of vertices |
| surfaces | Surfaces |
| meshName | Node name |
| const AABB& getAABB |
( |
| ) |
const |
|
nodiscardinline |
Returns the local space axis aligned bounding box
| vector<uint32_t>& getIndices |
( |
| ) |
|
|
nodiscardinline |
Return all the vertices indexes
| const vector<uint32_t>& getIndices |
( |
| ) |
const |
|
nodiscardinline |
Return all the vertices indexes
| const shared_ptr<Material>& getSurfaceMaterial |
( |
const uint32_t |
surfaceIndex | ) |
const |
|
nodiscardinline |
Returns the material for a given surface
- Parameters
-
| surfaceIndex | Zero based index of the surface |
| vector<shared_ptr<Surface> >& getSurfaces |
( |
| ) |
|
|
nodiscardinline |
| vector<Vertex>& getVertices |
( |
| ) |
|
|
nodiscardinline |
| const vector<Vertex>& getVertices |
( |
| ) |
const |
|
nodiscardinline |
| void setSurfaceMaterial |
( |
uint32_t |
surfaceIndex, |
|
|
const shared_ptr< Material > & |
material |
|
) |
| |
Changes the material of a given surface
- Parameters
-
| surfaceIndex | Zero based index of the Surface |
| material | New material for the Surface |