[ODE] odecpp.h
Russ Smith
russ at q12.org
Tue Jul 23 21:19:02 2002
> dSpace and dWorld have the nifty feature that they're "real"
> constructors don't take any arguments. So, I made the default
> constructors create a space/world and didn't provide a "set id to
> zero" constructor. Therefore, you could create an array of them and
> they'd all be properly initialized. Also, it would be impossible to
> use one before initializing it.
>
> Looks like Russ changed it. But if he hasn't changed the destructor,
> you need to change it to this:
yes - i changed dSpace so that both the simple and hash space can be
accessed. there *are* some situations where the simple space is
preferable to the hash space:
(1) you're trying to debug some collision problem and you think it
might be the space code. the simple space is, well, simpler.
(2) simple space is faster for < n objects (where 'n' is some number
that i never measured but might be, e.g. 3-5).
the problem is actually that people can unwittingly create dSpace.
it should be an abstract class. thus, i have made dSpace::dSpace() a
protected member (checked into CVS).
russ.
--
Russell Smith
http://www.q12.org