From: SourceForge.net <no...@so...> - 2011-03-27 18:32:33
|
Bugs item #3234230, was opened at 2011-03-22 03:12 Message generated for change (Comment added) made by patrickh You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=437247&aid=3234230&group_id=43735 Please note that this message will contain a full copy of the comment thread, including the initial issue submission, for this request, not just the latest update. Category: GMTL Group: HEAD Status: Open Resolution: None Priority: 5 Private: No Submitted By: Nobody/Anonymous (nobody) Assigned to: Patrick Hartling (patrickh) Summary: AABox/AABox sweep intersection problem Initial Comment: Version: GMTL 0.5.2-1 deb The attached file demonstrates that the AABox/AABox sweep intersection test returns a false positive if any component of the relative velocity of the two boxes is zero. ---------------------------------------------------------------------- >Comment By: Patrick Hartling (patrickh) Date: 2011-03-27 13:32 Message: Ignore my question. I didn't realize that the bug tracker showed comments in reverse chronological order. I now understand that the proposed change was incorrect. ---------------------------------------------------------------------- Comment By: Patrick Hartling (patrickh) Date: 2011-03-27 13:31 Message: The proposed patch causes a test case in the test suite to fail. Specifically, it breaks gmtlTest::IntersectionTest::testIntersectAABoxSweep() (see Test/TestSuite/TestCases/IntersectionTest.cpp). Does that mean that that test is incorrect or that the patch is incorrect? ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2011-03-23 03:24 Message: Eek! I just looked at the patch I added and it is _wrong_. Really wrong. Sorry for the noise. If I come up with a better patch, I'll post it later. ---------------------------------------------------------------------- Comment By: Nobody/Anonymous (nobody) Date: 2011-03-22 22:57 Message: Here's the patch that I am using to correct this problem. Sorry about the formatting -- I don't have a Sourceforge account, so I can't attach files. *** Intersection.h.orig 2011-03-22 20:54:30.198177237 -0700 --- /usr/include/gmtl-0.5.2/gmtl/Intersection.h 2011-03-22 20:54:36.771836476 -0700 *************** *** 152,157 **** --- 152,161 ---- { overlap1[i] = (box1.getMin()[i] - box2.getMax()[i]) / path[i]; } + else + { + return false; + } if ((box2.getMax()[i] > box1.getMin()[i]) && (path[i] < DATA_TYPE(0))) { *************** *** 161,166 **** --- 165,174 ---- { overlap2[i] = (box1.getMax()[i] - box2.getMin()[i]) / path[i]; } + else + { + return false; + } } // Calculate the first time of overlap ---------------------------------------------------------------------- You can respond by visiting: https://sourceforge.net/tracker/?func=detail&atid=437247&aid=3234230&group_id=43735 |