27

I am attempting to run a program that uses OpenGL to render a model in a viewport through VNC unsuccessfully.

The error message I receive is - Xlib: extension "GLX" missing on display ":1.0".

It was my understanding that VNC can be configured to render all graphics remotely and send a compressed screen grab from the display buffer to the local client. This would seem to negate the need for GLX extensions on the local client. Can VNC be configured this way and could you briefly describe how?

Remote host:

vncserver on RHEL 5

Local client:

UltraVNC on Windows XP

3
  • Will the OpenGL program work locally on the RH#L5 console? Will it work remotely via X-Windows? If not, it won't work on VNC.
    – kmarsh
    Commented Aug 24, 2010 at 18:00
  • 2
    Why is this a Community Wiki?
    – Chris S
    Commented Aug 24, 2010 at 18:07
  • I thought if it were a community wiki people could edit the question to make it more relevant for archival. Commented Aug 25, 2010 at 15:13

3 Answers 3

18

I'm using x11vnc to gain remote access to whatever the monitor is displaying. x11vnc talks to the local X11 server and copies the framebuffer from the server to the client via vnc. Since the local X11 server renders everything with hardware acceleration, I get hardware accelerated OpenGL over VNC, even with all the cool desktop effects. This is how I start x11vnc:

x11vnc -rfbauth ~/.vnc/passwd  -display :0 -forever -bg -repeat -nowf -o ~/.vnc/x11vnc.log

I think almost any vnc viewer works, but I'd recommend turbovnc or tigervnc. I tried VirtualGL first, and it works fine, but not for the whole desktop, only for individual OpenGL applications.

It is even possible to change resolution on the display/vnc using xrandr. E.g. like this:

xrandr -q (to see available modes and outputs)
xrandr --output DVI-I-0 --mode "1024x768" (change mode on DVI output)

(It is possible to add new resolutions if the available modes aren't enough, but that's outside the scope here.)

So now I have a fully OpenGL hardware accelerated and resizable VNC session.

1
  • 1
    Tried this approach with xfce4 and blender on a Tesla K80 GCE machine... it worked flawlessly. Gnome-shell still wouldn't display properly for some reason, as always. askubuntu.com/questions/229989/…
    – Ray Foss
    Commented Dec 21, 2017 at 21:41
17

You may want to look at Virtual GL

Quote: "VirtualGL is an open source package which gives any Unix or Linux remote display software the ability to run OpenGL applications with full 3D hardware acceleration"

1

Disable the special Video Hook driver that UltraVNC uses, or use TightVNC.

Since the UltraVNC driver is used to improve performance, it drops any kind of video processing done on the Video Card, such as OpenGL.

The video driver that UltraVNC installs this by default, it makes it so it cannot display OpenGL graphics. Note that disabling the driver will drastically decrease performance. Also note that while displaying items rendered in OpenGL performance will suffer on both ends, as the client machine now has a lot more work to do, and the bandwidth required is a lot higher. Don't expect anything over 4 seconds per frame (not 4 fps, more like 0.25 fps)

6
  • When you say disable the video hook in UltraVNC you are referring to the local client? Wouldn't the vncserver running on the remote host have to be configured instead? Commented Aug 25, 2010 at 15:14
  • No, I mean the local client. UltraVNC includes a video driver that is installed with it. Unless you explicitly say otherwise, the video driver will attempt to process all of the video on the client end so that it can compress and stream it for use over the network. Sometimes it is possible to specify on the viewer that you do not want to use this feature, but UltraVNC (at least used to) have a tendency to ignore this.
    – IceMage
    Commented Aug 25, 2010 at 17:04
  • Also, remote and local depend on your perspective. When I say local, I really mean the Host (the computer that is listening for new connections), and Remote meaning the computer making the connection. I'll correct this for future posts.
    – IceMage
    Commented Aug 25, 2010 at 17:12
  • OK - I guess I am using the opposite lingo. When I installed the UltraVNC viewer I don't believe it had a video driver it installed. The UltraVNC server I know does, but I am not using that. I am using vncserver on a RHEL5 machine as the host. Commented Aug 25, 2010 at 17:32
  • So my real question is, how do I configure vncserver to not send GLX commands but rather send simply a compressed screen from the display buffer to the UltraVNC viewer? Commented Aug 25, 2010 at 17:32

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .