Alpha could be that you haven’t asked for a destination alpha channel (you may not get one unless you ask for one), and depth component could be a bad projection matrix setup. Without more information, we can’t say anything.
Projection matrix is OK. But I still don’t know how you setup your pixel format.
My next guess on the depth component is that you don’t enable depth test. No depth test means no depth writes either, so you’re left with whatever the depth clear value is set to, which is 1.0 by default.
glEnable(GL_DEPTH_TEST) solves the problem but what do you mean by “Alpha could be that you haven’t asked for a destination alpha channel (you may not get one unless you ask for one)”?
When you setup the pixel format, you tell the OS what you want. For example, 8 bits of red green and blue, and 24 bits Z. If you don’t say you also want 8 bits alpha, you don’t get any bits at all. So if you want an alpha channel, you must tell the OS you want one. And you need an alpha channel to be able to draw and then read back alpha values. This is the destination alpha channel. Don’t confuse this with the source alpha, the alpha you set in glColor for example. Even though you don’t have a destination alpha channel, you can still perform (some types of) alpha blending since it’s only uses the source alpha channel.
For example, with GLUT, you add GLUT_ALPHA to glutInitDisplayMode, just like you ask for a depth buffer with GLUT_DEPTH, and a stencil buffer with GLUT_STENCIL.
If you instead use the PIXELFORMATDESCRIPTOR under Win32, you specify the amount of alpha bits in cAlphaBits field. Again, just like you put the number of depth bits cDepthBits, and same for cStencilBits, and so on.