diff options
author | Sergej Reich <sergej.reich@googlemail.com> | 2013-03-07 21:53:16 +0400 |
---|---|---|
committer | Sergej Reich <sergej.reich@googlemail.com> | 2013-03-07 21:53:16 +0400 |
commit | 643b0be4cb3f73bd876493d2a7bd6f76ef27cf06 (patch) | |
tree | 33fa8c08a902176f4204b6cc6a18702997bd90ba /extern/bullet2/src/LinearMath/btConvexHullComputer.cpp | |
parent | 46d32c89f6df911120579d00dd6e1246536cb6d8 (diff) |
bullet: Update to current svn, r2636
Apply patches in patches directory, remove patches that were applied
upstream.
If you made changes without adding a patch, please check.
Fixes [#32233] exporting bullet format results in corrupt files.
Diffstat (limited to 'extern/bullet2/src/LinearMath/btConvexHullComputer.cpp')
-rw-r--r-- | extern/bullet2/src/LinearMath/btConvexHullComputer.cpp | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/extern/bullet2/src/LinearMath/btConvexHullComputer.cpp b/extern/bullet2/src/LinearMath/btConvexHullComputer.cpp index 4fd81dac107..3fd77df8da5 100644 --- a/extern/bullet2/src/LinearMath/btConvexHullComputer.cpp +++ b/extern/bullet2/src/LinearMath/btConvexHullComputer.cpp @@ -1931,11 +1931,15 @@ void btConvexHullInternal::merge(IntermediateHull& h0, IntermediateHull& h1) } } - -static bool pointCmp(const btConvexHullInternal::Point32& p, const btConvexHullInternal::Point32& q) +class pointCmp { - return (p.y < q.y) || ((p.y == q.y) && ((p.x < q.x) || ((p.x == q.x) && (p.z < q.z)))); -} + public: + + bool operator() ( const btConvexHullInternal::Point32& p, const btConvexHullInternal::Point32& q ) const + { + return (p.y < q.y) || ((p.y == q.y) && ((p.x < q.x) || ((p.x == q.x) && (p.z < q.z)))); + } +}; void btConvexHullInternal::compute(const void* coords, bool doubleCoords, int stride, int count) { @@ -2026,7 +2030,7 @@ void btConvexHullInternal::compute(const void* coords, bool doubleCoords, int st points[i].index = i; } } - points.quickSort(pointCmp); + points.quickSort(pointCmp()); vertexPool.reset(); vertexPool.setArraySize(count); |