TITLE: How to transform a set of 3D vectors into a 2D plane, from a view point of another 3D vector?
QUESTION [19 upvotes]: I googled around a bit, but usually I found overly-technical explanations, or other, more specific Stackoverflow questions on how 3D computer graphics work. I'm sure I can find enough resources for this eventually, but I figured that it's good material for this site...
Lets say that I have a 3D space, with x, y and z coordinates. Then, I have a set of vectors (vertices in computer graphics, I suppose) in that space (they can be forming a cube, for example).
How do I go about transforming them for rendering on a 2D plane (screen)? I need to get x and y coordinates of 2D vectors, but, they need to be dependent on a specific point in space - the camera. When I move the camera, the x and y values should change.
I guess the process will go something like this:

Translate the 3D vectors according to the camera's x, y and z.
Rotate the 3D vectors according to the camera's theta and phi (I will need a lot of to polar coordinate system and from polar coordinate system conversions for this, but sin and cos aren't expensive, right?)
x = x/z, y = y/z, for transforming into 2D, I think, not sure about this part at all, I think I saw it somewhere.
Scale all vectors according to the camera's distance from the scene (or something else?)
Render.

I brainstormed these on the fly, there are probably a tonne of better solutions. Also, please try to keep the math simple, as I only know basic trig and calc up to the chain rule, I'm not sure what are people actually using for this. I heard something about "rotation matrices", what are they, exactly? (Well, I'm about to Google that now, but can't hurt me to get an answer here as well.) Also, what are the standard directions for xyz space? (Is z "up"?)

REPLY [3 votes]: I attended Professor Neil Dodgson's undergraduate lecture series at Cambridge University where he outlined a series of matrix manipulations that in combination, give the result you are asking for. From his 1998 lecture notes: