[DEV] remove an assert ==> create some eratic comportment, and coorect build after licence change

This commit is contained in:
Edouard DUPIN 2017-10-02 23:32:06 +02:00
parent 078fc33309
commit 96d6ff59d1
2 changed files with 6 additions and 1 deletions

View File

@ -6,6 +6,7 @@
* @copyright 2017, Edouard DUPIN * @copyright 2017, Edouard DUPIN
* @license MPL v2.0 (see license file) * @license MPL v2.0 (see license file)
*/ */
#pragma once
#include <ephysics/body/Body.hpp> #include <ephysics/body/Body.hpp>
#include <etk/math/Transform3D.hpp> #include <etk/math/Transform3D.hpp>
#include <ephysics/collision/shapes/AABB.hpp> #include <ephysics/collision/shapes/AABB.hpp>

View File

@ -303,7 +303,11 @@ void EPAAlgorithm::computePenetrationDepthAndContactPoints(const Simplex& _simpl
EPHY_INFO(" point=" << points[indexNewVertex]); EPHY_INFO(" point=" << points[indexNewVertex]);
EPHY_INFO("close point=" << triangle->getClosestPoint()); EPHY_INFO("close point=" << triangle->getClosestPoint());
EPHY_INFO(" ==>" << wDotv); EPHY_INFO(" ==>" << wDotv);
EPHY_ASSERT(wDotv >= 0.0, "depth penetration error"); if (wDotv < 0.0) {
EPHY_ERROR("depth penetration error " << wDotv);
continue;
}
EPHY_ASSERT(wDotv >= 0.0, "depth penetration error " << wDotv);
float wDotVSquare = wDotv * wDotv / triangle->getDistSquare(); float wDotVSquare = wDotv * wDotv / triangle->getDistSquare();
if (wDotVSquare < upperBoundSquarePenDepth) { if (wDotVSquare < upperBoundSquarePenDepth) {
upperBoundSquarePenDepth = wDotVSquare; upperBoundSquarePenDepth = wDotVSquare;