Calculating the target on an ITerrainSceneNode

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
badday
Posts: 102
Joined: Mon Aug 16, 2010 1:14 pm

Calculating the target on an ITerrainSceneNode

Post by badday »

Hi,

I´m acutally trying to calculate the target (which is a cursor position) on an ITerrainSceneNode. I´m actually totaly new to that stuff and couldn´t find any useful information so far.

I think there are at least four things to look at: cursor position, camera position, camera eye direction and the ITerrainScene node.

But I´ve got no idea how to calculate the target by using this.

Maybe someone has the time to tell me how to.


Thanks.
hbraun
Posts: 28
Joined: Tue Dec 16, 2008 7:33 pm
Location: Porto Alegre, Brazil
Contact:

Post by hbraun »

Hi..

Try out these things:

"device->getSceneManager()->getSceneCollisionManager()"

...And then you have...

* getCollisionPoint;
* getRayFromScreenCoordinates (maybe is this exactly what you); and
* getSceneNodeAndCollisionPointFromRay...etc

Good luck,

Braun
Post Reply