Today I have been looking for methods of running OpenGL – and ultimately Vulkan – on a headless server so that we can do thin client experiments on Vookoo, our vulkan wrapper library.
There is an excellent article here: http://renderingpipeline.com/2012/05/windowless-opengl/ on the subject which gave me some basic clues about running GLX, the interface to OpenGL on Linux machines.
I did a few little experiments and discovered that it was quite easy to run OpenGL examples such as glxgears http://linux.die.net/man/1/glxgears from an SSH session provided you had a working X server running and knew the display name.
$ ssh email@example.com
$ export DISPLAY=:1 # note: you should check this variable on your xterm
And you should have glxgears (from the mesa utils) running on your remote desktop.
Of course, we don’t want to actually do this as you can’t see the result unless you are in the room with the server, but it does enable us to create framebuffers on our server, render to them and pump the result to an android app or web page.
Thin clients are likely to become more popular as internet data rates improve. The old HTML-based web model is likely to migrate to web pages that are merely windows on dynamic server generated content.
Our goal this summer at Goldsmiths College is to create a sample thin client VR system that pumps 3D content to a smartphone or desktop app so that multiple users can play a game or enjoy a visual experience on a single server.