Archived

This topic is now archived and is closed to further replies.

dukenukem

1.0f = how many pixel ?

Recommended Posts

when i create a square which one side is 1.0f what is its pixel size?i mean 64 or 128 or 256 or another. i am a newbie.so this question may be weird.sorry for that.

Share this post


Link to post
Share on other sites
If your projection is orthographic, 1.0f will correspond to a fixed number of pixels (depending on the window size and the projection matrix though).
If your projection is perspective, 1.0f will correspond to a higher number of pixels for close objects, and a lower number of pixels for far objects. (by close or far , I mean close to or far away the camera)
I think it is clear explanation. At least I hope it is.

Edited by - vincoof on February 19, 2002 3:42:03 PM

Share this post


Link to post
Share on other sites
quote:
Original post by Eber Kain
If you want to modify specific pixel locations, look into the glDrawPixels function.

No, please don''t . Setup an orthographic projection matrix and then use glViewport to make screen coordinates equal to pixel coordinates.

Share this post


Link to post
Share on other sites