History

fix warning

ZappoMan committed 9 years ago

Commit da404ce1 parent dcb70aa2 files · +3 −7Browse files

Showing the changes to libraries/shared/src/TriangleSet.cpp (1 of 2 files). Show all

Unified · Split

libraries/shared/src/TriangleSet.cpp+2−6
@@ -81,7 +81,7 @@ void TriangleSet::balanceOctree() { · 80 unmodified lines
8181
8282 // insert all the triangles
8383
84− for (int i = 0; i < _triangles.size(); i++) {
84+ for (size_t i = 0; i < _triangles.size(); i++) {
8585 _triangleOctree.insert(i);
8686 }
8787
@@ -153,10 +153,6 @@ void TriangleSet::TriangleOctreeCell::reset(const AABox& bounds, int depth) { · 65 unmodified lines
153153 clear();
154154 _bounds = bounds;
155155 _depth = depth;
156− if (depth <= MAX_DEPTH) {
157− int childDepth = depth + 1;
158− _children.clear();
159− }
160156 }
161157
162158 void TriangleSet::TriangleOctreeCell::debugDump() {
@@ -176,7 +172,7 @@ void TriangleSet::TriangleOctreeCell::debugDump() { · 13 unmodified lines
176172 }
177173 }
178174
179−void TriangleSet::TriangleOctreeCell::insert(int triangleIndex) {
175+void TriangleSet::TriangleOctreeCell::insert(size_t triangleIndex) {
180176 const Triangle& triangle = _allTriangles[triangleIndex];
181177 _population++;
182178 // if we're not yet at the max depth, then check which child the triangle fits in