Conceptually, a viewport is a 2-D rectangle into which a three dimensional scene is projected. (In Direct3D, the rectangle exists as coordinates within a DirectDraw surface that the system uses as a rendering target.) The projection transformation converts vertices into the coordinate system used for the viewport.
You use a viewport in Direct3D to specify the following features in your application:
The clipping volume is the area that defines the part of your scene that will appear on the render target surface. If the viewport you choose is small enough so that parts of your scene will not be visible, you should clip the parts that will be off of the screen so that the system will avoid the overhead of rendering those parts of the scene. For more information, see Clipping Volumes.