What screen coordinate system is used in Irrlicht?

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
pir
Posts: 24
Joined: Wed Apr 29, 2009 8:15 pm

What screen coordinate system is used in Irrlicht?

Post by pir »

I'm trying to do pick selection by using ISceneCollisionManager::getSceneNodeFromScreenCoordinatesBB.
What is the screen coordinate system used when defining the screen coordinates to use?
Is the coordinates of the upper left corner (0,0) and lower right (width, height)? I've tried to search the forum and documentation about this, but without any luck.

hope someone have time to answer my question.
tomhancocks
Posts: 15
Joined: Fri Jan 02, 2009 1:25 pm
Location: Around
Contact:

Post by tomhancocks »

0,0 is the upper left, and width,height is indeed the lower right.
Systemerror
Posts: 98
Joined: Fri Oct 03, 2008 1:25 pm
Location: UK
Contact:

Post by Systemerror »

It uses the right handed cartesian co ordinate system (X, Y, Z)

X = width
Y = height
Z = 3D line between the two

Y(height)
| _ X(twidth)
/
Z(towards the viewer)


Like my graph? lol
Last edited by Systemerror on Thu Apr 30, 2009 10:13 pm, edited 3 times in total.
-System error
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

screen has no z axis, and the rest is not important then.
Systemerror
Posts: 98
Joined: Fri Oct 03, 2008 1:25 pm
Location: UK
Contact:

Post by Systemerror »

Oops, sorry I just skimmed through his first post, well atleast he knows for future refference :P
-System error
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Oh, in that case: Irrlicht uses a left-handed systm, just as DirectX.
Acki
Posts: 3496
Joined: Tue Jun 29, 2004 12:04 am
Location: Nobody's Place (Venlo NL)
Contact:

Post by Acki »

Systemerror wrote: X(height going downwards)
| _ Y(to the right)
/
Z(towards the viewer)


Like my graph? lol
maybe if it was correct... :lol:
X - you're wrong: it goes to the right !!!
Y - you're wrong: it goes up !!!
Z - you're wrong: it's the opposite direction !!! ;)
while(!asleep) sheep++;
IrrExtensions:Image
http://abusoft.g0dsoft.com
try Stendhal a MORPG written in Java
Systemerror
Posts: 98
Joined: Fri Oct 03, 2008 1:25 pm
Location: UK
Contact:

Post by Systemerror »

That's what tiredness does to you, it's not what I meant.

Now edited to right handed system even though Irrlicht uses the left like D3D, I suddenly started thinking of OpenGL strangly enough - old habbits ....
-System error
Post Reply