Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Quote from <a href="https://www.opengl.org/discussion_boards/showthread.php/133880-Diference-between-GL_MODELVIEW-and-GL_PROJECTION" rel="nofollow" title="OpenGL.org forum">opengl.org forum</a>:</p> <blockquote> <p>The projection matrix is used to create your viewing volume. Imagine a scene in the real world. You don't really see everything around you, only what your eyes allow you to see. If you're a fish for example you see things a bit broader. So when we say that we set up the projection matrix we mean that we set up what we want to see from the scene that we create. I mean you can draw objects anywhere in your world. If they are not inside the view volume you won't see anything. When you create the view volume imagine that you create 6 clipping planes that define your field of view.</p> <p>As for the modelview matrix, it is used to make various transformations to the models (objects) in your world. Like this you only have to define your object once and then translate it or rotate it or scale it. </p> <p>You would use the projection matrix before drawing the objects in your scene to set the view volume. Then you draw your object and change the modelview matrix accordingly. Of course you can change your matrix midway of drawing your models if for example you want to draw a scene and then draw some text (which with some methods you can work easier in orthographic projection) then change back to modelview matrix.</p> <p>As for the name modelview it has to do with the duality of modeling and viewing transformations. If you draw the camera 5 units back, or move the object 5 units forwards it is essentially the same.</p> </blockquote>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload