Page 1 of 1

get the size of a Model and trace from one point to another

Posted: Wed May 13, 2009 12:34 pm
by Sylar
Okay, after I got the resolution change at runtime and the camera thing to work, I have two new questions:
How can I get the position of the 8 corners from an IAnimatedMeshSceneNode bounding box?
And how can I trace from one point to another point? E.g I have two points (0|8|0) and (0|-8|0). I want to trace between these points and check if there is something (get the Pointer of this Object) and if so I want the Point were the trace hits.

I need this to create a vegetation system, I want to fill a terrain randomly with trees (I have wrote something like this in Lite-C for Gamestudio but I don't know how to port this to Irrlicht).

PS: Sorry for my bad english.

Posted: Wed May 13, 2009 12:49 pm
by Sylence
For the bounding box there is ISceneNode::getTransformedBoundingBox() and aabbox3d has a method for obtaining its edges.

For the collision you should check ISceneCollisionManager.