Templatised SurfaceMesh class on vertex type.

Replaced 'SurfaceVertex' with PositionMaterial and PositionMaterialNormal classes.
Different surface extractors can now work with different vertex types.
This commit is contained in:
David Williams
2010-10-17 21:13:46 +00:00
parent 56ec37f5e2
commit 9e1de4ba72
28 changed files with 460 additions and 176 deletions

View File

@ -29,7 +29,7 @@ freely, subject to the following restrictions:
namespace PolyVox
{
void Mesh::buildFromMesh(SurfaceMesh* pMesh)
void Mesh::buildFromMesh(SurfaceMesh<PositionMaterialNormal>* pMesh)
{
//First we copy the vertices across.
//We also keep track of where each vertex went
@ -186,7 +186,7 @@ namespace PolyVox
}
}
void Mesh::fillMesh(SurfaceMesh* pMesh)
void Mesh::fillMesh(SurfaceMesh<PositionMaterialNormal>* pMesh)
{
pMesh->clear();