Fix compilation errors on Visual Studio

This commit is contained in:
Daniel Chappuis 2016-03-01 18:40:22 +01:00
parent d0481e0901
commit 41d0c60d49
2 changed files with 6 additions and 6 deletions

View File

@ -223,7 +223,7 @@ void HeightField::generateHeightField() {
// Generate the graphics mesh to render the height field
void HeightField::generateGraphicsMesh() {
std::vector<uint> indices;
std::vector<unsigned int> indices;
int vertexId = 0;
for (int i=0; i<NB_POINTS_WIDTH; i++) {
@ -238,10 +238,10 @@ void HeightField::generateGraphicsMesh() {
// Triangle indices
if ((i < NB_POINTS_WIDTH - 1) && (j < NB_POINTS_LENGTH - 1)) {
int v1 = vertexId;
int v2 = vertexId + 1;
int v3 = vertexId + NB_POINTS_LENGTH;
int v4 = vertexId + NB_POINTS_LENGTH + 1;
unsigned int v1 = vertexId;
unsigned int v2 = vertexId + 1;
unsigned int v3 = vertexId + NB_POINTS_LENGTH;
unsigned int v4 = vertexId + NB_POINTS_LENGTH + 1;
// First triangle
indices.push_back(v1);

View File

@ -49,7 +49,7 @@ class Mesh : public Object3D {
// -------------------- Attributes -------------------- //
// A triplet of vertex indices for each triangle
std::vector<std::vector<uint> > mIndices;
std::vector<std::vector<unsigned int> > mIndices;
// Vertices coordinates (local space)
std::vector<Vector3> mVertices;