Projection transformation
Combined matrix, mapping frustum to a cube:
To get normalized image plane coordinates (valid range [-1,1] both) , just drop z in the result and convert from homogeneous to regular.
To get pixel coordinates, translate by 1,
and scale x and y (Viewport transformation)