how can i change the ratio of mapping of World coordinate system to screen.i am using
MFC with OpenGL and drawing with the paint message.
What do you mean precisely by the “ratio of mapping of World coordinate system to screen?” Are you refering to the aspect ratio? If so, you can change that in your gluPerspective call (assuming you are using that). You should call this every time you get a WM_SIZE message (you’ll get one once the window has been created, so you don’t need another one in OnCreate). If you aren’t using gluPerspective, and are instead using glFustrum, then you will have to change your top/bottom/left/right values according to the new size.
by mapping i mean that when i draw a cube
at (0,0,0) i see the cube. when i draw it at
(1,1,1), it is not visible i.e. it goes outside the window.my question is that how to code such that even i draw a cube at say…
(10,10,10) it is visible. to put it other way
how to code such that a large world can be seen in a window?