fix warning

This commit is contained in:
ZappoMan 2017-05-13 09:29:32 -07:00
parent dcb70aa504
commit da404ce2ce
2 changed files with 3 additions and 7 deletions

View file

@ -81,7 +81,7 @@ void TriangleSet::balanceOctree() {
// insert all the triangles
for (int i = 0; i < _triangles.size(); i++) {
for (size_t i = 0; i < _triangles.size(); i++) {
_triangleOctree.insert(i);
}
@ -153,10 +153,6 @@ void TriangleSet::TriangleOctreeCell::reset(const AABox& bounds, int depth) {
clear();
_bounds = bounds;
_depth = depth;
if (depth <= MAX_DEPTH) {
int childDepth = depth + 1;
_children.clear();
}
}
void TriangleSet::TriangleOctreeCell::debugDump() {
@ -176,7 +172,7 @@ void TriangleSet::TriangleOctreeCell::debugDump() {
}
}
void TriangleSet::TriangleOctreeCell::insert(int triangleIndex) {
void TriangleSet::TriangleOctreeCell::insert(size_t triangleIndex) {
const Triangle& triangle = _allTriangles[triangleIndex];
_population++;
// if we're not yet at the max depth, then check which child the triangle fits in

View file

@ -22,7 +22,7 @@ class TriangleSet {
_allTriangles(allTriangles)
{ }
void insert(int triangleIndex);
void insert(size_t triangleIndex);
void reset(const AABox& bounds, int depth = 0);
void clear();