Re: Kinematic Collision

"David Black" <[email protected]>
Newsgroups gmane.games.devel.algorithms
Message-ID <[email protected]>
>>>>
  Yes, I agree with that. That's why we exposed a set of
  functions to test exactly this (if a given position is valid),
  However it puts the power (or the burden, depending on your
  point of view) in the hands of users: -they- have to test for
  valid positions. At the time we felt that it was more
  efficient than running the "useless" depenetration code
  automatically all the time.
  The only problem with PhysX is that the queries to test for
  valid positions only return a boolean answer (position is
  valid or not). When it is not, the depenetration vector is not
  provided. So it is not as useful as it could be. (Boolean
  queries are a lot faster and often enough, so that was the
  reason IIRC).
  - Pierre
<<<<

Requiring a seperate query to test for initial intersection seems very
wasteful, since you are going to have to traverse the
broadphase/midphase structures twice as often as otherwise. Not to
mention the maths that would have been saved by providing the result
with the sweep query.

Also I think the depenetration vector is the important part... I guess
you could perform some sort of binary search to depenetrate but that
seems error prone and expensive. 

I dont think it is terribly difficult to provide depenetration results,
the way I do it is detect initial penetration and if detected compute
the direction of least penetration and perform another sweep(with just
the relevant parts of the objects) to determine the depentration
distance. It probably amounts to 50 lines of code per sweep test, which
could be easily disabled with a flag if not needed.

David

-- 
http://www.fastmail.fm - Send your email first class


------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day 
trial. Simplify your report design, integration and deployment - and focus on 
what you do best, core application coding. Discover what's new with 
Crystal Reports now.  http://p.sf.net/sfu/bobj-july
_______________________________________________
GDAlgorithms-list mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gdalgorithms-list
Archives:
http://sourceforge.net/mailarchive/forum.php?forum_name=gdalgorithms-list
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.