From 7da1c518771b6d2d875b68ca6e264bd363777594 Mon Sep 17 00:00:00 2001 From: Andrew Meadows Date: Tue, 14 Apr 2015 14:55:42 -0700 Subject: [PATCH] whoops, missed a file --- libraries/physics/src/ShapeManager.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libraries/physics/src/ShapeManager.cpp b/libraries/physics/src/ShapeManager.cpp index 2a73f5d28f..dd67c2c73a 100644 --- a/libraries/physics/src/ShapeManager.cpp +++ b/libraries/physics/src/ShapeManager.cpp @@ -35,7 +35,7 @@ btCollisionShape* ShapeManager::getShape(const ShapeInfo& info) { // Very small or large objects are not supported. float diagonal = 4.0f * glm::length2(info.getHalfExtents()); const float MIN_SHAPE_DIAGONAL_SQUARED = 3.0e-4f; // 1 cm cube - const float MAX_SHAPE_DIAGONAL_SQUARED = 3.0e6f; // 1000 m cube + //const float MAX_SHAPE_DIAGONAL_SQUARED = 3.0e6f; // 1000 m cube if (diagonal < MIN_SHAPE_DIAGONAL_SQUARED /* || diagonal > MAX_SHAPE_DIAGONAL_SQUARED*/ ) { // qCDebug(physics) << "ShapeManager::getShape -- not making shape due to size" << diagonal; return NULL; @@ -104,11 +104,9 @@ void ShapeManager::collectGarbage() { ShapeReference* shapeRef = _shapeMap.find(key); if (shapeRef && shapeRef->refCount == 0) { // if the shape we're about to delete is compound, delete the children first. - auto shapeType = ShapeInfoUtil::fromBulletShapeType(shapeRef->shape->getShapeType()); - if (shapeType == SHAPE_TYPE_COMPOUND) { + if (shapeRef->shape->getShapeType() == COMPOUND_SHAPE_PROXYTYPE) { const btCompoundShape* compoundShape = static_cast(shapeRef->shape); const int numChildShapes = compoundShape->getNumChildShapes(); - QVector> points; for (int i = 0; i < numChildShapes; i ++) { const btCollisionShape* childShape = compoundShape->getChildShape(i); delete childShape;