glVertex2f - problem
Hi.
I have a littel problem. Why does this work glRasterPos2f(400.0f, 400,0f) ans this glVertex2f(400.0f, 400,0f) not?
(Window: 800x600);
Ok this is maybe a bad question.
Is there a way to convert it? Or must i try it over 20 times, until i found the correct paramters?
thx, Austrina Coder
if you''re not in orthographic mode, you''re
drawing your vertices appx 400 screen sizes
outside your current scene
if you actually WANT to use perspective projection
and you want something thats "400x400" on the screen,
that''d actually be glVertex2f(1/400, 1/400);
think of your screen as 1 unit...
leftmost is 0, rightmost is 1.. everything in between
is a decimal.
in orthographic projection you dont have to worry about any
of this though. you just have to stay within the coordinates
you initialize with gluOrtho (see above post).
i suggest you check out nehe.gamedev.net tutorial 21
-eldee
;another space monkey;
[ Forced Evolution Studios ]
drawing your vertices appx 400 screen sizes
outside your current scene

if you actually WANT to use perspective projection
and you want something thats "400x400" on the screen,
that''d actually be glVertex2f(1/400, 1/400);
think of your screen as 1 unit...
leftmost is 0, rightmost is 1.. everything in between
is a decimal.
in orthographic projection you dont have to worry about any
of this though. you just have to stay within the coordinates
you initialize with gluOrtho (see above post).
i suggest you check out nehe.gamedev.net tutorial 21
-eldee
;another space monkey;
[ Forced Evolution Studios ]
-eldee;another space monkey;[ Forced Evolution Studios ]
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement