Skip to content

Commit

Permalink
Merge pull request #1326 from ctrlaltdavid/fix/avatar-crash
Browse files Browse the repository at this point in the history
Fix avatar crash
  • Loading branch information
digisomni committed Sep 7, 2021
2 parents 18cc4cd + 96708f5 commit 542e070
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion libraries/physics/src/MultiSphereShape.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ void MultiSphereShape::calculateDebugLines() {
break;
}
}
}
}
calculateChamferBox(_debugLines, radiuses, axes, _midPoint);
} else if (_spheres.size() == 8) {
std::vector<glm::vec3> axes;
Expand All @@ -508,6 +508,10 @@ void MultiSphereShape::connectEdges(std::vector<std::pair<glm::vec3, glm::vec3>>
}

void MultiSphereShape::calculateChamferBox(std::vector<std::pair<glm::vec3, glm::vec3>>& outLines, const std::vector<float>& radiuses, const std::vector<glm::vec3>& axes, const glm::vec3& translation) {
if (radiuses.size() == 0) {
return;
}

std::vector<std::pair<glm::vec3, glm::vec3>> sphereLines;
calculateSphereLines(sphereLines, glm::vec3(0.0f), radiuses[0]);

Expand Down

0 comments on commit 542e070

Please sign in to comment.