Closed totaam closed 8 years ago
You could try to enable Usage OpenGL to see if chrome switches to that for rendering.
My openGL works (there is no error message after I upgraded pythonGL via pip), I think. glxgears give much higher framerate over xpra than over ssh forwarded x11. (Indeed it is higher than glxgears running on client) glxinfo shows
OpenGL vendor string: VMware, Inc. OpenGL renderer string: Gallium 0.4 on llvmpipe (LLVM 3.4, 256 bits)
Which is what xpra always show me (forwarded X11 the rendering string is MESA). What other test can I use to see if my openGL over xpra is working or not?
But the google chrome video still shows a blank.
However, what does work is when I uncheck "use hardware acceleration when available" under chrome. So it does seem that the trouble is with graphic acceleration over xpra, at least for old ubuntu 14.04.
However, for now, I could get a workaround by unchecking use hardware acceleration when available under chrome.
OK, I'm writing too fast. I found that despite giving no error message, the openGL may not be working in my case after all. When I select from xpra applet to enable OpenGL (which was not enabled by default somehow), all of my forwarded window become blank. So there must really be some problem with openGL in my set up. The error message is this. I am using rgb raw pixel forwarding. What is the problem? Should I file a new bug report since this is not a chrome problem, but an OpenGL problem?
2016-04-14 16:30:21,021 do_paint_rgb32 error Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/xpra/client/window_backing_base.py", line 314, in do_paint_rgb32 success = self._do_paint_rgb32(img_data, x, y, width, height, rowstride, options) File "/usr/lib/python2.7/dist-packages/xpra/client/gl/gl_window_backing_base.py", line 634, in _do_paint_rgb32 return self._do_paint_rgb(32, img_data, x, y, width, height, rowstride, options) File "/usr/lib/python2.7/dist-packages/xpra/client/gl/gl_window_backing_base.py", line 650, in _do_paint_rgb self.gl_init() File "/usr/lib/python2.7/dist-packages/xpra/client/gl/gl_window_backing_base.py", line 406, in gl_init glTexParameteri(GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MAX_LEVEL, 0) File "errorchecker.pyx", line 53, in OpenGL_accelerate.errorchecker._ErrorChecker.glCheckError (src/errorchecker.c:1218) GLError: GLError( err = 1281, description = 'invalid value', baseOperation = glTexParameteri, cArguments = ( GL_TEXTURE_RECTANGLE_ARB, GL_TEXTURE_MAX_LEVEL, 0, )
However, what does work is when I uncheck "use hardware acceleration when available" under chrome. So it does seem that the trouble is with graphic acceleration over xpra, at least for old ubuntu 14.04. [[BR]] No, see comment:1, what you want is probably vglrun if you have a real graphics card in that system you can use. Xpra does not care about what is used for rendering (opengl or not), it only captures the pixels that get rendered onto the virtual screen, it's likely that the newer google chrome now uses an opengl API that doesn't work properly with your vfb. This may be fixed by using a better / newer version of vfb (ie: newer xdummy), or using vglrun.
Unfortunately, no, it still does not work. I use vglrun. It works over xpra (the glxgears performances tripled and rendering strings in glxinfo shows virtualgl). But when I use vglrun to launch chrome, it still show a blank square for video if I do not uncheck "use acceleration" in chrome. So it is not just an opengl issue, unfortunately.
So it is not just an opengl issue, unfortunately. [[BR]] What makes you think that? I think it clearly is, whatever acceleration chrome uses does not work with the vfb. Little to do with xpra.
But why then doesn't it work with vglrun?
It should, but there's more to it than just vglrun, maybe chrome is probing the display for xv adapters or something. What I am saying is that the vfb is likely to be the problem: chrome tries to use some hardware feature that is not present in the vfb. (and the failure to detect this looks like a real bug in chrome)
I will try it here when I get a chance with a more up to date system than ubuntu 14.04.
OK, I'll probably upgrade to ubuntu 16.04 when it comes out, though it is my production system so I may not have time to upgrade it for a little while. Thanks for looking into this! I'll change the priority to lower, since there is a workable workaround here (simply disabling hardware acceleration in chrome).
Note: I think xdummy is still horribly broken in 16.04, so this may not help at all.
Ubuntu now have snappy package. Essentially it is a package that contains all its dependencies rather than relying on the package that comes with the OS. Will this help, or is Xdummy and python too much to include in a single package? https://developer.ubuntu.com/en/snappy/build-apps/ I'm sorry ubuntu is such a pain. It is unfortunately too much of a pain to switch to fedora, now that I've been with apt-get system for over a decade---debian is just too out of date.
(I did start out in linux with redhat, from 7.3 to 9.0, until redhat split up into fedora and Redhat Enterprise. Back then there wasn't yum so dependency hell was very real for me back then!)
Thanks for looking into this. It is not too much hassle right now, since I could just disable acceleration on chrome. It's not too much of a penalty.
I have actually fixed the bug from comment:3 in r13237, done as part of the work in #1275: older versions of Ubuntu and Debian will be supported in the next release! These changes should allow you to run with opengl enabled on older systems. (though they may still be greylisted for opengl by default) Note: this fixes the opengl client side, NOT the video forwarding issue with chrome...
Tried and things are definitely messed up, not sure how much of it is virtualbox's opengl driver's fault and how much of it is Ubuntu's - but this is not an xpra bug so I am closing as invalid.
There is a workaround: as per comment:1, I can make google-chrome run OK by using virtualgl. You can automate this by using "exec-wrapper = vglrun" in your xpra config. This requires that a "real" X11 display is running on this server system for providing accelerated opengl. (setting up virtualgl is out of scope)
Without vglrun, opengl applications render badly or not at all (black rectangle), the google-chrome window is garbled and half of it is being rendered on the "real" display which it should NOT have access to at all.
Issue migrated from trac ticket # 1165
component: core | priority: minor | resolution: invalid
2016-04-14 02:14:51: jiang.qian created the issue