# What is the Viewport?

Can someone please explain to me what the Viewport is. I've read the OpenGL wiki and doc.gl but they give me a definition that I don't understand at all. The definition they gave me is "glViewport specifies the affine transformation of x and y from normalized device coordinates to window coordinates. Let (xnd,ynd) be normalized device coordinates.". I don't understand what that means.

• "Unfortunately, no one can be told what the Viewport is. You have to see it for yourself." On a serious note: songho.ca/opengl/gl_transform.html Sep 3 at 19:46

The viewport as specified by glViewport is just the rectangle in pixels on the screen that you wish to render to. Usually it's from (0,0) to (width, height) in pixels, but you could set it to a smaller region (or larger, for that matter) and it will basically scale the image as it's being rendered.