Wireframe debugging plane3df

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
denzelbro
Posts: 50
Joined: Wed Jun 27, 2018 11:53 pm

Wireframe debugging plane3df

Post by denzelbro »

As the title suggest. how do I check the bounds or at least visualize this plane3df? Is this some sort of infinite geometry or plane?
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: Wireframe debugging plane3df

Post by CuteAlien »

Yeah, planes are infinite. Visualizing itself is tricky - but in many cases you need them for collisions so you can color the parts colliding against it.

Or you could use the getIntersectionWithLine function of plane3d. As line you could use for example the camera-view vector (camera position and camera target). Then draw a line starting from the intersection point (if there is any) and as end point add the plane-normal to the start-point (and some scaling factor for longer debug lines if you want).
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
denzelbro
Posts: 50
Joined: Wed Jun 27, 2018 11:53 pm

Re: Wireframe debugging plane3df

Post by denzelbro »

CuteAlien wrote:Yeah, planes are infinite. Visualizing itself is tricky - but in many cases you need them for collisions so you can color the parts colliding against it.

Or you could use the getIntersectionWithLine function of plane3d. As line you could use for example the camera-view vector (camera position and camera target). Then draw a line starting from the intersection point (if there is any) and as end point add the plane-normal to the start-point (and some scaling factor for longer debug lines if you want).
Thanks CuteAlien! this explains a lot and I will try your tip there. :)
Post Reply