OpenGL Programming Guide: The Official Guide to Learning OpenGL, Version 4.3, Eighth Edition
by Dave Shreiner, Graham Sellers, John M. Kessenich, Bill M. Licea-Kane
Viewing
If we display a typical geometric model’s coordinates directly onto the display device, we probably won’t see much. The range of coordinates in the model (e.g., –100 to +100 meters) will not match the range of coordinates consumed by the display device (e.g., 0 to 1919 pixels) and it is cumbersome to restrict ourselves to coordinates that would match. In addition, we want to view the model from different locations, directions, and perspectives. How do we compensate for this?
Fundamentally, the display is a flat, fixed, two-dimensional rectangle while our model contains extended three-dimensional geometry. This chapter will show how to project our model’s three-dimensional coordinates onto the fixed two-dimensional screen coordinates. ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access