Here's a link to my code.
A lot of the basic math stuff was taken from this guy, who wrote the book I paid almost $100 for. Since I signed up with amazon's referal program, I will have a link up soon for everyone to purchase the book from.
Next up is antialiasing and texture mapping. My plane will have a checkerboard and my sphere will have a texture of the earth. I hope everyone enjoys.