Scratchapixel has a nice tutorial on writing a basic rasterizer here. Also, you could use the projection algorithm here to get the position of the vertices in screen space, then use Bresenham's algorithm or DDA to draw lines in between. If you want to fill them too you can use scanline (you can find it on Wikipedia).
For ellipsoids, you can either just turn them into a triangle mesh, or the approach here might work, although I haven't tried it.
The Z-Buffer algorithm is very straightforward, just calculate the distance from the point to the camera and store that somewhere for each pixel, then make sure that that's less than whatever was already there.