How do I create an OpenGL context in my program (C++) which will be used purely internally? That is, it will render a scene, then I will grab the pixel data to use in the rest of the program (saving to an image is a close-enough analogy — I'm fine with the framebuffer stuff, I just need to create the context).
I don't need a window at all, and this only needs to work on Unix (specifically OSX and Ubuntu, if the solution is different for each then Ubuntu is more important). I don't want to use GLUT or similar if I can help it.