What is a view matrix?
Matrices are created to define the position of items in a coordinate system as well as how these things are projected on the monitor. There are actually several matrices used in 3D game programming they are called the:
Projection Matrix
Model Matrix
View Matrix
World Matrix
These are all multiplied together and stored as another matrix named the ModelViewProjection Matrix. By using this one, you can do one transformation to move 3D coordinate into 2d screen.
A view matrix is 4 Vec3 structs that represents the camera position, it's viewport & frustrum. Three of these vectors are the rotation matrix, representing the Up, Right & Forward (Look) axes. The other vector encodes the position. It can also be viewed at as an array of 16 floats.
3D Game Programming uses view matrixes to "transform" vertices of object. The viewmatrix is used in our WorldToScreen() function to convert 3D world positions of entities to 2D screen space.
The viewport transformation locates the viewer in world space, transforms the vertices into camera space. In camera space, the viewer, is at the origin, looking in the positive z-direction. Remember Direct3D uses a lefthanded system, so z is positive number. The matrix moves the objects in the world around a camera's position - the origin & orientation.