saladin
19-11-2007 13:31:25
Hi,
I was working on terrain clamping for my project which uses python-ogre ogreNewt. At the start of my program immediately after I created the physics world I set its size like this:
But when running the program I found that the world size is still around (-100, -100, -100) to (100, 100, 100) which might be the default newton world size. And strangely if I call the set size code again during runtime in the pycrust console, the world size seems to be changed correctly.
I'm wondering if this has anything to do with the fact that OgreNewt.World's NewtonWorld member variable in C++ is not wrapped to be a python object. (call getNewtonWorld() on OgreNewt.World gives an error) Maybe someone can wrap that in the coming release as it is very important that the programmer can set and get physics world boundary reliably.
Any help will be enormously appreciated.
I was working on terrain clamping for my project which uses python-ogre ogreNewt. At the start of my program immediately after I created the physics world I set its size like this:
self.worldAABB = ogre.AxisAlignedBox(ogre.Vector3(-400, -400, -400), ogre.Vector3(400, 400, 400))
self.physicsWorld.setWorldSize(self.worldAABB)
But when running the program I found that the world size is still around (-100, -100, -100) to (100, 100, 100) which might be the default newton world size. And strangely if I call the set size code again during runtime in the pycrust console, the world size seems to be changed correctly.
I'm wondering if this has anything to do with the fact that OgreNewt.World's NewtonWorld member variable in C++ is not wrapped to be a python object. (call getNewtonWorld() on OgreNewt.World gives an error) Maybe someone can wrap that in the coming release as it is very important that the programmer can set and get physics world boundary reliably.
Any help will be enormously appreciated.