Graphics acceleration not working in ubuntu desktop 12.10

Bug #1085596 reported by Andrew Kirby on 2012-12-02
86
This bug affects 18 people
Affects Status Importance Assigned to Milestone
Cross distro support for Samsung Chromebook (ARM based)
Low
Unassigned

Bug Description

No visible graphics acceleration in ubuntu 12.10 (unity,compiz)

Installed:

xserver-xorg-video-armsoc == accelerated Xorg video driver.
chromium-mali-opengles == OpenGL ES support

Copied exynos.conf to from chromeO to Subuntu system

Hardware acceleration defaults to software rendering.

Marcin Juszkiewicz (hrw) wrote :

So we need to check what is needed to get it working on OpenGL ES drivers. It was possible but I never used Unity on ARM so do not know how to get there.

Marcin Juszkiewicz (hrw) wrote :

Unity should at least run - /usr/lib/nux/unity_support_test says:

OpenGL vendor string: ARM
OpenGL renderer string: Mali-T604
OpenGL version string: OpenGL ES 2.0

Not software rendered: yes
Not blacklisted: yes
GLX fbconfig: no
GLX texture from pixmap: no
GL npot or rect textures: no
GL OES EGL image: yes
EGL KHR image pixmap: yes
EGL version is 1.4+: yes

Unity supported: yes

But how good? No idea - I refuse to use Unity.

Andrew Kirby (mrandrewkirby) wrote :

Tried running the test with the following results. Unity is currently running but extremely slowly.

Is there anywhere I can test OpenGLES is working? as I dont believe its working right now. I think the problem is not Unity itself.

user@localhost:/usr/lib/nux$ unity_support_test
Sorry, command-not-found has crashed! Please file a bug report at:
https://bugs.launchpad.net/command-not-found/+filebug
Please include the following information with the report:

command-not-found version: 0.3
Python version: 3.2.3 final 0
Distributor ID: Ubuntu
Description: Ubuntu 12.10
Release: 12.10
Codename: quantal
Exception information:

unsupported locale setting
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/CommandNotFound/util.py", line 24, in crash_guard
    callback()
  File "/usr/lib/command-not-found", line 69, in main
    enable_i18n()
  File "/usr/lib/command-not-found", line 40, in enable_i18n
    locale.setlocale(locale.LC_ALL, '')
  File "/usr/lib/python3.2/locale.py", line 541, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting

Marcin Juszkiewicz (hrw) wrote :

apt-get install glmark2-es2 mesa-utils-extra

Run "es2_info" - it should give you into about Mali OpenGL ES status. Then run glmark2-es2 - it will give you ~100 points.

Andrew Kirby (mrandrewkirby) wrote :
Download full text (4.1 KiB)

Running es2_info gives:

root@localhost:~# es2_info
EGL_VERSION = 1.4 Midgard-"r1p2-00bet0"
EGL_VENDOR = ARM
EGL_EXTENSIONS = EGL_KHR_config_attribs EGL_KHR_image EGL_KHR_image_base EGL_KHR_fence_sync EGL_ARM_wait_sync EGL_KHR_gl_texture_2D_image EGL_KHR_gl_renderbuffer_image EGL_KHR_gl_texture_cubemap_image EGL_KHR_image_pixmap
EGL_CLIENT_APIS = OpenGL_ES
GL_VERSION: OpenGL ES 2.0
GL_RENDERER: Mali-T604
GL_EXTENSIONS:
    GL_ARM_rgba8, GL_ARM_mali_shader_binary,
    GL_ARM_texture_format_rgba16_la16, GL_OES_depth24, GL_OES_depth_texture,
    GL_OES_packed_depth_stencil, GL_OES_rgb8_rgba8, GL_EXT_read_format_bgra,
    GL_OES_compressed_paletted_texture, GL_OES_compressed_ETC1_RGB8_texture,
    GL_OES_standard_derivatives, GL_OES_EGL_image, GL_OES_EGL_image_external,
    GL_OES_texture_npot, GL_OES_vertex_half_float,
    GL_OES_required_internalformat, GL_OES_vertex_array_object,
    GL_OES_mapbuffer, GL_EXT_texture_format_BGRA8888, GL_EXT_texture_rg,
    GL_EXT_texture_type_2_10_10_10_REV, GL_OES_fbo_render_mipmap,
    GL_OES_element_index_uint, GL_EXT_occlusion_query_boolean,
    GL_EXT_blend_minmax, GL_EXT_discard_framebuffer,
    GL_OES_get_program_binary, GL_ARM_mali_program_binary, GL_OES_texture_3D,
    GL_EXT_texture_storage, GL_EXT_multisampled_render_to_texture

Then running glmark-es2 gives the following, it severely corrupted the screen whilst it was working and the total score was 20 so it looks like there are problems.

root@localhost:~# glmark2-es2
=======================================================
    glmark2 2012.08
=======================================================
    OpenGL Information
    GL_VENDOR: ARM
    GL_RENDERER: Mali-T604
    GL_VERSION: OpenGL ES 2.0
=======================================================
[build] use-vbo=false: FPS: 29 FrameTime: 34.483 ms
[build] use-vbo=true: FPS: 21 FrameTime: 47.619 ms
[texture] texture-filter=nearest: FPS: 22 FrameTime: 45.455 ms
[texture] texture-filter=linear: FPS: 21 FrameTime: 47.619 ms
[texture] texture-filter=mipmap: FPS: 21 FrameTime: 47.619 ms
[shading] shading=gouraud: FPS: 21 FrameTime: 47.619 ms
[shading] shading=blinn-phong-inf: FPS: 22 FrameTime: 45.455 ms
[shading] shading=phong: FPS: 21 FrameTime: 47.619 ms
[bump] bump-render=high-poly: FPS: 21 FrameTime: 47.619 ms
[bump] bump-render=normals: FPS: 22 FrameTime: 45.455 ms
[bump] bump-render=height: FPS: 23 FrameTime: 43.478 ms
[effect2d] kernel=0,1,0;1,-4,1;0,1,0;: FPS: 21 FrameTime: 47.619 ms
[effect2d] kernel=1,1,1,1,1;1,1,1,1,1;1,1,1,1,1;: FPS: 22 FrameTime: 45.455 ms
[pulsar] light=false:quads=5:texture=false: FPS: 22 FrameTime: 45.455 ms
[desktop] blur-radius=5:effect=blur:passes=1:separable=true:windows=4: FPS: 11 FrameTime: 90.909 ms
[desktop] effect=shadow:windows=4: FPS: 19 FrameTime: 52.632 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 18 FrameTime: 55.556 ms
[buffer] columns=200:interleave=false:update-dispersion=0.9:update-fraction=0.5:update-method=subdata: FPS: 18 FrameTime: 55.556 ms
[buffer] columns=200:interleave=true:update-dispersion=0.9:update-fraction=0.5:update-method=map: FPS: 19 FrameTime: 52.63...

Read more...

Rune K. Svendsen (runeks) wrote :

Sorry for going a bit off topic, but can anyone tell me what this LC_ALL environment variable error is all about? I gather it's related to the system locale, but I can't figure out why it occurs. The error is present in Andres Kirby's comment #3:

   unsupported locale setting
   Traceback (most recent call last):
     File "/usr/lib/python3/dist-packages/CommandNotFound/util.py", line 24, in crash_guard
       callback()
     File "/usr/lib/command-not-found", line 69, in main
       enable_i18n()
     File "/usr/lib/command-not-found", line 40, in enable_i18n
       locale.setlocale(locale.LC_ALL, '')
     File "/usr/lib/python3.2/locale.py", line 541, in setlocale
       return _setlocale(category, locale)
   locale.Error: unsupported locale setting

And I see it often as well. I've never seen this error on my amd64 system, and as far as I can see this variable is not set here:

   rune@rune-desktop:~$ echo $LC_ALL

Rune K. Svendsen (runeks) wrote :

To get back on topic, I'm experiencing the same issues as you, Andrew. Here's some hopefully relevant output from Xorg.0.log:

 OMAP5432 with PowerVR SGX544 MP, Mali-T60x
[ 545.869] (++) using VT number 7

[ 545.869] (WW) Falling back to old probe method for armsoc
[ 545.869] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
[ 545.870] (II) ARMSOC(0): Creating default Display subsection in Screen section
 "DefaultScreen" for depth/fbbpp 24/32
[ 545.870] (**) ARMSOC(0): Depth 24, (--) framebuffer bpp 32
--
[ 545.903] (II) ARMSOC(0): RandR 1.2 enabled, ignore the following RandR disabled message.
[ 545.903] (==) ARMSOC(0): DPMS enabled
[ 545.951] (--) RandR disabled
[ 545.974] (EE) AIGLX error: dlopen of /usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so: cannot open shared object file: No such file or directory)
[ 545.974] (EE) AIGLX: reverting to software rendering
[ 545.974] (II) AIGLX: Screen 0 is not DRI capable
[ 545.981] (II) AIGLX: Loaded and initialized swrast
[ 545.981] (II) GLX: Initialized DRISWRAST GL provider for screen 0

I can't find armsoc_dri.so in the Chrome OS filesystem though.

Andrew Kirby (mrandrewkirby) wrote :

Hi,

apparently armsoc_dri.so does not exist, there is no such thing.

If thats the case I am not sure why the system calls for it. But I have the same message in my Xorg.0.log and it is defaulting to software rendering mode like yours

When Running OpenGL ES tests I get a severely corrupted screen so something is really not right.

Rune K. Svendsen (runeks) wrote :

I stripped the timestamps from both Ubuntu's and Chrome OS' Xorg.0.log and made a diff of the two files. This should tell us something about what Chrome OS does differently than Ubuntu wrt. to X. I'm attaching the output of the diff.

One thing that is different between Ubuntu and Chrome OS, is that the DRI and DRI2 module in Ubuntu is built into the X server. On Chrome OS it loads the two files /usr/lib/xorg/modules/extensions/libdri.so and /usr/lib/xorg/modules/extensions/libdri2.so instead. These files are symbolic links to the two files of the same name in /usr/lib/opengl/xorg-x11/extensions/ in Chrome OS.

So it looks like this might be the problem. Ubuntu tries to use the built-in DRI implementation but Chrome OS has its own, probably tailor-made for the GPU in question.

Chrome OS has a lot of X extensions that it loads while Ubuntu loads built-in extensions. The problem is that we can't use these with Ubuntu's X because it's a different version than Chrome's. I'm wondering whether it's possible to just completely replace Ubuntu's X server with the one found in Chrome OS. That's not a long term solution of course, but if it makes it work for now we're at least better off.

Rune K. Svendsen (runeks) wrote :

Is this some of the stuff we need?

http://www.malideveloper.com/developer-resources/drivers/open-source-mali-gpus-linux-exadri2-and-x11-display-drivers.php
http://www.malideveloper.com/developer-resources/drivers/open-source-mali-gpus-linux-kernel-device-drivers.php

It provides the EXA and DRI2 modules for X. But how to build them I really don't know. I also don't know if we're able to copy the parts missing from the above from Chrome OS. As far as I understand, the missing parts are the OpenGL ES implementation and probably also implementations for OpenVG and OpenCL.

Marcin, do you have working OpenGL ES in Ubuntu? You mention here that it works, but is that in Ubuntu? https://plus.google.com/105007947798310229700/posts/ervfAJnGoHu

Andrew Kirby (mrandrewkirby) wrote :

Yes it would be useful to know what Marcin is running, I'm sure it's Linaro but with many tweaks, it would be useful if we could get an image that OpenGL ES works on so we can attempt to find out why it doesn't work on other distros.
Marcin can you help with this?

Marcin Juszkiewicz (hrw) wrote :

https://plus.google.com/105007947798310229700/posts/gGyBq79FTVa was on my Chromebook with Ubuntu 13.04 installed.

I have to install Ubuntu again before playing with anything - just restored it to stock Chromium.

Marcin Juszkiewicz (hrw) wrote :

Rune: Those are for Mali 200/400. Chromebook has 604.

Rune K. Svendsen (runeks) wrote :

It could simply be that Andrew and I are running 12.10 instead of 13.04. I will try updating to 13.04 and see how it goes.

Marcin Juszkiewicz (hrw) wrote :

Under 13.04 screen looks terrible when OpenGL ES is running ;(

Yuri Pole (x3qt-dev) on 2012-12-22
Changed in chromebook-arm:
status: New → Confirmed
importance: Undecided → Low
james (lyons-dj) wrote :

/usr/lib/nux/unity_support_test -p -c
OpenGL vendor string: ARM
OpenGL renderer string: Mali-T604
OpenGL version string: OpenGL ES 2.0

Not software rendered: yes
Not blacklisted: yes
GLX fbconfig: no
GLX texture from pixmap: no
GL npot or rect textures: no

Compiz supported: yes

/usr/lib/nux/unity_support_test -p
OpenGL vendor string: ARM
OpenGL renderer string: Mali-T604
OpenGL version string: OpenGL ES 2.0

Not software rendered: yes
Not blacklisted: yes
GLX fbconfig: no
GLX texture from pixmap: no
GL npot or rect textures: no
GL OES EGL image: yes
EGL KHR image pixmap: yes
EGL version is 1.4+: yes

Unity supported: yes

james (lyons-dj) wrote :

.xsession-errors repoorts:

compiz (core) - Info: Loading plugin: core
compiz (core) - Info: Starting plugin: core
compiz (core) - Info: Loading plugin: ccp
compiz (core) - Info: Starting plugin: ccp
compiz (core) - Info: Loading plugin: composite
compiz (core) - Info: Starting plugin: composite
compiz (core) - Info: Loading plugin: opengl
compiz (core) - Info: Unity is not supported by your hardware. Enabling software rendering instead (slow).
compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Starting plugin: opengl
compiz (core) - Info: Loading plugin: compiztoolbox
compiz (core) - Info: Starting plugin: compiztoolbox
compiz (core) - Info: Loading plugin: decor
compiz (core) - Info: Starting plugin: decor
compiz (core) - Info: Loading plugin: vpswitch
compiz (core) - Info: Starting plugin: vpswitch
compiz (core) - Info: Loading plugin: snap
compiz (core) - Info: Starting plugin: snap
compiz (core) - Info: Loading plugin: mousepoll
compiz (core) - Info: Starting plugin: mousepoll
compiz (core) - Info: Loading plugin: resize
compiz (core) - Info: Starting plugin: resize
compiz (core) - Info: Loading plugin: place
compiz (core) - Info: Starting plugin: place
compiz (core) - Info: Loading plugin: move
compiz (core) - Info: Starting plugin: move
compiz (core) - Info: Loading plugin: wall
compiz (core) - Info: Starting plugin: wall
compiz (core) - Info: Loading plugin: grid
compiz (core) - Info: Starting plugin: grid
compiz (core) - Info: Loading plugin: regex
compiz (core) - Info: Starting plugin: regex
compiz (core) - Info: Loading plugin: imgpng
compiz (core) - Info: Starting plugin: imgpng
compiz (core) - Info: Loading plugin: session
compiz (core) - Info: Starting plugin: session
I/O warning : failed to load external entity "/home/user/.compiz/session/10902a0d6497562a11135623280283009800000008280033"
compiz (core) - Info: Loading plugin: gnomecompat
compiz (core) - Info: Starting plugin: gnomecompat
compiz (core) - Info: Loading plugin: animation
compiz (core) - Info: Starting plugin: animation
** Message: applet now removed from the notification area
compiz (core) - Info: Loading plugin: fade
compiz (core) - Info: Starting plugin: fade
compiz (core) - Info: Loading plugin: unitymtgrabhandles
compiz (core) - Info: Starting plugin: unitymtgrabhandles
compiz (core) - Info: Loading plugin: workarounds
compiz (core) - Info: Starting plugin: workarounds
compiz (core) - Info: Loading plugin: scale
compiz (core) - Info: Starting plugin: scale
compiz (core) - Info: Loading plugin: expo
compiz (core) - Info: Starting plugin: expo
compiz (expo) - Warn: failed to bind image to texture
compiz (core) - Info: Loading plugin: ezoom
compiz (core) - Info: Starting plugin: ezoom
compiz (core) - Info: Loading plugin: unityshell
compiz (core) - Info: Starting plugin: unityshell

james (lyons-dj) wrote :

 unity --replace &
[1] 1384
user@localhost:~$ compiz (core) - Info: Loading plugin: core
compiz (core) - Info: Starting plugin: core
unity-panel-service: no process found
compiz (core) - Info: Loading plugin: ccp
compiz (core) - Info: Starting plugin: ccp
compizconfig - Info: Backend : gsettings
compizconfig - Info: Integration : true
compizconfig - Info: Profile : unity
compiz (core) - Info: Loading plugin: composite
compiz (core) - Info: Starting plugin: composite
compiz (core) - Info: Loading plugin: opengl
compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Starting plugin: opengl
compiz (core) - Info: Loading plugin: compiztoolbox
compiz (core) - Info: Starting plugin: compiztoolbox
compiz (core) - Info: Loading plugin: decor
compiz (core) - Info: Starting plugin: decor
compiz (core) - Info: Loading plugin: vpswitch
compiz (core) - Info: Starting plugin: vpswitch
compiz (core) - Info: Loading plugin: snap
compiz (core) - Info: Starting plugin: snap
compiz (core) - Info: Loading plugin: mousepoll
compiz (core) - Info: Starting plugin: mousepoll
compiz (core) - Info: Loading plugin: resize
compiz (core) - Info: Starting plugin: resize
compiz (core) - Info: Loading plugin: place
compiz (core) - Info: Starting plugin: place
compiz (core) - Info: Loading plugin: move
compiz (core) - Info: Starting plugin: move
compiz (core) - Info: Loading plugin: wall
compiz (core) - Info: Starting plugin: wall
compiz (core) - Info: Loading plugin: grid
compiz (core) - Info: Starting plugin: grid
compiz (core) - Info: Loading plugin: regex
compiz (core) - Info: Starting plugin: regex
compiz (core) - Info: Loading plugin: imgpng
compiz (core) - Info: Starting plugin: imgpng
compiz (core) - Info: Loading plugin: session
compiz (core) - Info: Starting plugin: session
compiz (core) - Info: Loading plugin: gnomecompat
compiz (core) - Info: Starting plugin: gnomecompat
compiz (core) - Info: Loading plugin: animation
compiz (core) - Info: Starting plugin: animation
compiz (core) - Info: Loading plugin: fade
compiz (core) - Info: Starting plugin: fade
compiz (core) - Info: Loading plugin: unitymtgrabhandles
compiz (core) - Info: Starting plugin: unitymtgrabhandles
compiz (core) - Info: Loading plugin: workarounds
compiz (core) - Info: Starting plugin: workarounds
compiz (core) - Info: Loading plugin: scale
compiz (core) - Info: Starting plugin: scale
compiz (core) - Info: Loading plugin: expo
compiz (core) - Info: Starting plugin: expo
compiz (expo) - Warn: failed to bind image to texture
compiz (core) - Info: Loading plugin: ezoom
compiz (core) - Info: Starting plugin: ezoom
compiz (core) - Info: Loading plugin: unityshell
compiz (core) - Info: Starting plugin: unityshell

Marcin Juszkiewicz (hrw) wrote :

James: so it is supported or not? Would it be worth something if we report bug on Unity?

james (lyons-dj) wrote :

Marcin, seems to be a bug with Unity/Compiz. I have to restart Unity until it reports:

compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Unity is fully supported by your hardware.

Rather than:

compiz (core) - Info: Unity is not supported by your hardware. Enabling software rendering instead (slow).

However none of the Desktop effects seem to work anyway, seems to always be in software rendering mode.

I can't use Compiz Settings Manager, as it doesn't work under Chrubuntu 12.10. So I can only make a few changes from the Command line, but none of the effects that use 3D hardware seem to work, even when:

 compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Unity is fully supported by your hardware.

On a side note, the screen artifacts seen when running OpenGL ES Apps go away if no window manager is running, tho I'm not sure what help that is. The Screen Artifacts also effect the performance, I get a score of 35 in glmark2-es2 with artifacts and a score of 135 without artifacts.

james (lyons-dj) wrote :

I managed to get CCSM working under 12.10 and now I have full Compiz/Unity OpenGL effects working.

First the local settings are broken in Chubuntu so if you try and run Compiz Config Settings Manager(CCSM) you'll see:

ccsm

(process:6123): Gtk-WARNING **: Locale not supported by C library.
        Using the fallback 'C' locale.
Traceback (most recent call last):
  File "/usr/bin/ccsm", line 93, in <module>
    import ccm
  File "/usr/lib/python2.7/dist-packages/ccm/__init__.py", line 1, in <module>
    from ccm.Conflicts import *
  File "/usr/lib/python2.7/dist-packages/ccm/Conflicts.py", line 26, in <module>
    from ccm.Constants import *
  File "/usr/lib/python2.7/dist-packages/ccm/Constants.py", line 79, in <module>
    locale.setlocale(locale.LC_ALL, "")
  File "/usr/lib/python2.7/locale.py", line 531, in setlocale
    return _setlocale(category, locale)
locale.Error: unsupported locale setting

To fix this you need a file in your home dir .xprofile with some local settings, I used:

export LANGUAGE=en_US.UTF-8
export LANG=en_US.UTF-8
export LC_ALL=en_US.UTF-

Make the file, set it to the correct local settings for your computer, log out and back in and CCSM should work

Next it seems that the old Unity --replace Command is no longer used in 12.10 so grab this to replace it:

sudo add-apt-repository ppa:amith/ubuntutools
sudo apt-get update
sudo apt-get install unity-reset

Then run:

unity-resest&

In the terminal until you see the output:( Scroll back in the Terminal output to find this text )

compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Unity is fully supported by your hardware.

Once you see this, open ccsm and make sure the OpenGL is checked, you can also try Wobbly Windows, Desktop Cube, Rotate Cube, as they all use 3D Hardware to work.

I did have one systems freeze when I checked Desktop Cube the first time, but after a hard restart I was able to check it and it now works, so YMMV.

I also see a small amount of artifacts when moving Wobbly Windows, but not much.

We still need to send a bug report to Unity/Compiz because it's not detecting the 3D hardware every time as it should. I'd send the bug report, but I'm not sure where to send it?

james (lyons-dj) wrote :

You can enable WebGL in Chromium Browser by launching it from the command line with the:

chromium-browser --use-gl=egl

Switch.

Then goto the chrome://gpu-internals/ page to see that it's working.

Graphics Feature Status
Canvas: Software only. Hardware acceleration disabled.
Compositing: Hardware accelerated
3D CSS: Hardware accelerated
CSS Animation: Accelerated
WebGL: Hardware accelerated
WebGL multisampling: Hardware accelerated
Flash 3D: Hardware accelerated
Flash Stage3D: Unavailable. Hardware acceleration unavailable
Texture Sharing: Hardware accelerated
undefined: Hardware accelerated
Problems Detected
Accelerated 2D canvas is unavailable: either disabled at the command line or not supported by the current system.
Accelerated 2d canvas is unstable in Linux at the moment.
Stage3D is not supported on Linux.: 129848
Version Information
Data exported Sun Dec 23 2012 22:27:20 GMT-0500 (EST)
Chrome version 22.0.1229.94 (Developer Build 161065) Ubuntu 12.10
Operating system Linux 3.4.0
Software rendering list version 2.10
ANGLE revision 1275
2D graphics backend Skia
Driver Information
Initialization time 235
GPU0 VENDOR = 0x0000, DEVICE= 0x0000
Optimus false
AMD switchable false
Driver vendor
Driver version
Driver date
Pixel shader version 1.00
Vertex shader version 1.00
GL version 2.0
GL_VENDOR ARM
GL_RENDERER Mali-T604
GL_VERSION OpenGL ES 2.0
GL_EXTENSIONS GL_ARM_rgba8 GL_ARM_mali_shader_binary GL_ARM_texture_format_rgba16_la16 GL_OES_depth24 GL_OES_depth_texture GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_EXT_read_format_bgra GL_OES_compressed_paletted_texture GL_OES_compressed_ETC1_RGB8_texture GL_OES_standard_derivatives GL_OES_EGL_image GL_OES_EGL_image_external GL_OES_texture_npot GL_OES_vertex_half_float GL_OES_required_internalformat GL_OES_vertex_array_object GL_OES_mapbuffer GL_EXT_texture_format_BGRA8888 GL_EXT_texture_rg GL_EXT_texture_type_2_10_10_10_REV GL_OES_fbo_render_mipmap GL_OES_element_index_uint GL_EXT_occlusion_query_boolean GL_EXT_blend_minmax GL_EXT_discard_framebuffer GL_OES_get_program_binary GL_ARM_mali_program_binary GL_OES_texture_3D GL_EXT_texture_storage GL_EXT_multisampled_render_to_texture

But, WebGL programs won't work because of the artifacts, you'll have to kill your window server and run Chromium without it to run WebGL apps.

Anyone know how to get this working with Firefox?

Greg Nwosu (greg-nwosu) wrote :

john i ran the unity-reset program but i dont see the

compiz (core) - Info: Unity is fully supported by your hardware.
compiz (core) - Info: Unity is fully supported by your hardware.

messages, also i dont get the option for the cube in ccsm (which seems to load ok btw)

G

Lone Rebel (lonerebelz) wrote :

Would one of you guys who have graphics acceleration running *please* document the steps to get accelerated graphics up and running? It sounds like you need to update to 12.1 first. I updated to 12.1 and then errored out on plymouth when booting up. I went into chrome os mounted the ubuntu partition and added the override manual files to the plymouth files in /etc/init that was documented on the chrubuntu arm thread. But 12.1 stopped on the plymouth bug. I eventually just reinstalled chrubuntu and am back to 12.04.

Any help would be much appreciated. Thanks.

Greg Nwosu (greg-nwosu) wrote :

am running 12.10 but i am not getting the hw acceleration, steps are not clear and i doubt anyone has been fully successful otherwise bug will be closed, however chromebooks have been selling out all over so it wont be long until some hacker figures it out. i think someone tried acceleration on 13.04 but that version of ubuntu is very unstable

Tom Townsend (tom-towny) wrote :

@LoneRebel - for updating to 12.10 I suggest following the steps laid out by Andy Kirby in the comments here : http://marcin.juszkiewicz.com.pl/2012/11/23/chromebook-support-for-ubuntu/
I will warn you that X acceleration is obviously non existent and it does have a few more bugs than 12.04. You should look at setting $LC_ALL to get rid of the python errors and settings the host (/etc/hosts) properly before upgrading as well.

Concerning the bug I have CCSM working and Chromium intermittently details the Mali T604 as the rendering hardware when forced to look for it. Otherwise Chromium reports the rendering hardware as "Software Rasteriser".

james (lyons-dj) wrote :

OpenGL Acceleration is working fine for me under Unity/Compiz in 12.10. Just make sure OpenGL and Composite are checked in CCSM, that's all you should really need.

james (lyons-dj) wrote :

If you copy over the Flash Plugin from the Chrome OS you can run Chromium with Hardware Flash Acceleration as well.

chromium-browser --use-gl=egl --ppapi-flash-path=/opt/google/chrome/pepper/libpepflashplayer.so --ppapi-flash-version=11.3.31.518 --ppapi-flash-args=enable_hw_video_decode=0,enable_stagevideo_auto=0,enable_trace_to_console=0

For some reason YouTube does not work, but everything else seems too. Full Screen HQ Hulu plays with no lag at all.

Rune K. Svendsen (runeks) wrote :

james, both Composite and OpenGL are checked in ccsm on my Chromebook, but Open GL isn't working.

Are all the tests working for you as well? Like glmark2-es2?

Did you do anything special to get it working? Please post a copy of your /var/log/Xorg.0.log

I'd love to get HW acceleration working but I can't.

james (lyons-dj) wrote :

There is a bug int the Mali OpenGL drivers with Compositing Window managers so in order to use most OpenGL you'll need to turn off Compositing.

It's best to install XFCE, in 12.10 Composting is off by default in XFCE. When you need to use OpenGL just log out of Unity and into XFCE.

Rune K. Svendsen (runeks) wrote :

Yippee! You're awesome james!

I just installed LXDE and it is noticeably faster. Probably because Unity was running OpenGL on the CPU via LLVM.

I now see a spinning horse running glmark2-es2, so that part works. Finally! Progress :o)

chrome://gpu-internals/ says everything is hardware accelerated except Canvas and "Flash Stage3D". As you mention, YouTube playback isn't hardware supported (it lags at 720p even) but I can't get vimeo.com to work either. I'm in Denmark to I can't test Hulu (only allowed in the US).

Does anyone know how to get strace to work properly? Chromium gives me errors in the terminal when I try to watch YouTube videos, so I'd like to see if it's trying to open non-existing files, but strace doesn't give the usual output. It says things like

pid 6296 stray syscall exit
pid 6296 stray syscall entr

and it doesn't print file names, just numbers:

open(NULL, O_RDONLY|O_NONBLOCK|O_ASYNC|O_LARGEFILE|O_NOFOLLOW|O_NOATIME|0x7ee00010) = 2129045360
open(NULL, O_RDONLY|O_DIRECTORY) = 2129045336
open(0xfffffffe, O_RDONLY) = 2129045336

Perhaps I should open a separate bug about that, but I'd just like to hear first if it's something simple.

james (lyons-dj) wrote :

Yes glmark-es2 and es2gears both work for me, you should post the output of es2_info under Unity as I can't understand why OpenGL isn't working under Unity/Compiz for you, yet it is for me.

I even have Quake3 running under OpenGL ES.

But under Unity/Compiz these programs give artifacts, very bad on the top of the screen, so I have to log in to XFCE to use them.

Rune K. Svendsen (runeks) wrote :

glmark2-es2 works under Unity as well, but not without artifacts. I suspect this is because of that bug you mention with the Mali driver and compositing.

This is the output I get when browsing to a YouTube video:

ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream
ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream
[1704:1704:209401382:ERROR:gl_surface.cc(83)] Not implemented reached in virtual bool gfx::GLSurface::Resize(const gfx::Size&)
ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream
ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream
[1704:1704:212986204:ERROR:gpu_video_decode_accelerator.cc(193)] Not implemented reached in void GpuVideoDecodeAccelerator::Initialize(media::VideoCodecProfile, IPC::Message*)HW video decode acceleration not available.
[WARNING:flash/platform/pepper/pep_videocodec.cpp(722)] Video decoder creation failed.
ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream
ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream

These messages all seem to be related to playing YouTube videos, as they only appear in the output after opening a YouTube video.

There's a difference between playing different videos on YouTube though. The above output is from playing this video http://www.youtube.com/watch?v=kDsXFIHnVPw
It doesn't even start to play. No audio or video.

This video though http://www.youtube.com/watch?v=WwG9of7EUi0 works, and only gives the output

[1957:1957:373349566:ERROR:gl_surface.cc(83)] Not implemented reached in virtual bool gfx::GLSurface::Resize(const gfx::Size&)

not the "HW video decode acceleration not available." error.

james (lyons-dj) wrote :

I don't know why the flash player doesn't work with Youtube, you can ignore the:

ALSA lib pcm_dmix.c:957:(snd_pcm_dmix_open) The dmix plugin supports only playback stream

These happen even during normal playback.

Rune K. Svendsen (runeks) wrote :

Could the reason be that Xorg is using software rendering? The following is present in my Xorg.0.log, is it present in yours too?

[ 5.857] (EE) AIGLX error: dlopen of /usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so: cannot open shared object file: No such file or directory)
[ 5.857] (EE) AIGLX: reverting to software rendering

Or perhaps we need XVideo support? I notice Chrome OS has the XVideo extension in a separate file, while it's built into X in Ubuntu. Are they building a special XVideo extension that is compatible with the T604?

Rune K. Svendsen (runeks) wrote :

One additional piece of info: it seems that when you pass the --use-gl=egl option to chromium, it will fail with the "Not implemented reached in void GpuVideoDecodeAccelerator::Initialize" error and the video will not play. If you remove that argument, the video plays. So it seems it tries to play via HW unit when --use-gl=egl is passed, but fails on some videos.

Rune K. Svendsen (runeks) wrote :

I'm thinking the binaries in this archive (link posted by Marcin to the mailing list) might be necessary for HW video acceleration: http://commondatastorage.googleapis.com/chromeos-localmirror/distfiles/openmax-0.0.1-r5.tbz2

I've copied the files over from the Chrome OS partition, but I still get the same error. I could be missing something though.

Rune K. Svendsen (runeks) wrote :

The following error happens because the X server loads the GLX module

[ 225.090] (EE) AIGLX error: dlopen of /usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so failed (/usr/lib/arm-linux-gnueabihf/dri/armsoc_dri.so: cannot open shared object file: No such file or directory)
[ 225.090] (EE) AIGLX: reverting to software rendering
[ 225.090] (II) AIGLX: Screen 0 is not DRI capable
[ 225.097] (II) AIGLX: Loaded and initialized swrast
[ 225.097] (II) GLX: Initialized DRISWRAST GL provider for screen 0

We can make it go away by disabling the glx module, by adding the following to exynos.conf:

Section "Module"
        Disable "glx"
EndSection

Now the above snippet disappears from Xorg.0.log.

Does anyone know a good test to confirm that it has actually made a difference?

What exactly is it that is software rendered when the above error happens? Are all Open GL operations software rendered when DRI isn't working? It doesn't look like it's the case since glmark2-es2 gets the same FPS/score regardless of whether this error is present or not.

Rune K. Svendsen (runeks) wrote :
Download full text (3.2 KiB)

Here's the unity_support output on my system.

rune@chromebook:~$ /usr/lib/nux/unity_support_test -p -c
libEGL warning: GLX/DRI2 is not supported
libEGL warning: DRI2: failed to open armsoc (search paths /usr/lib/arm-linux-gnueabihf/dri:${ORIGIN}/dri:/usr/lib/dri)
OpenGL vendor string: Mesa Project
OpenGL renderer string: Software Rasterizer
OpenGL version string: OpenGL ES 2.0 Mesa 9.0.1

Not software rendered: no
Not blacklisted: yes
GLX fbconfig: no
GLX texture from pixmap: no
GL npot or rect textures: no

Compiz supported: no
rune@chromebook:~$ /usr/lib/nux/unity_support_test -p
libEGL warning: GLX/DRI2 is not supported
libEGL warning: DRI2: failed to open armsoc (search paths /usr/lib/arm-linux-gnueabihf/dri:${ORIGIN}/dri:/usr/lib/dri)
OpenGL vendor string: Mesa Project
OpenGL renderer string: Software Rasterizer
OpenGL version string: OpenGL ES 2.0 Mesa 9.0.1

Not software rendered: no
Not blacklisted: yes
GLX fbconfig: no
GLX texture from pixmap: no
GL npot or rect textures: no
GL OES EGL image: no
EGL KHR image pixmap: no
EGL version is 1.4+: yes

Unity supported: no

This is the output whether or not I've blacklisted the glx module in exynos.conf. Here's the output of es2_info:

rune@chromebook:~$ es2_info
libEGL warning: GLX/DRI2 is not supported
libEGL warning: DRI2: failed to open armsoc (search paths /usr/lib/arm-linux-gnueabihf/dri:${ORIGIN}/dri:/usr/lib/dri)
EGL_VERSION = 1.4 (DRI2)
EGL_VENDOR = Mesa Project
EGL_EXTENSIONS = EGL_KHR_surfaceless_context
EGL_CLIENT_APIS = OpenGL OpenGL_ES OpenGL_ES2
GL_VERSION: OpenGL ES 2.0 Mesa 9.0.1
GL_RENDERER: Software Rasterizer
GL_EXTENSIONS:
    GL_EXT_blend_minmax, GL_EXT_multi_draw_arrays,
    GL_EXT_texture_filter_anisotropic, GL_EXT_texture_compression_dxt1,
    GL_EXT_texture_format_BGRA8888, GL_OES_depth24, GL_OES_element_index_uint,
    GL_OES_fbo_render_mipmap, GL_OES_mapbuffer, GL_OES_rgb8_rgba8,
    GL_OES_standard_derivatives, GL_OES_stencil8, GL_OES_texture_3D,
    GL_OES_texture_npot, GL_OES_depth_texture, GL_OES_packed_depth_stencil,
    GL_EXT_texture_type_2_10_10_10_REV, GL_APPLE_texture_max_level,
    GL_EXT_read_format_bgra, GL_NV_fbo_color_attachments,
    GL_OES_vertex_array_object, GL_EXT_texture_rg, GL_EXT_unpack_subimage,
    GL_NV_draw_buffers, GL_NV_read_buffer

I think it's looking for armsoc_dri.so (this is what Xorg looks after too if I don't disable the glx module).

I have Marcin's packages installed on the system:

rune@chromebook:~$ apt-cache policy xserver-xorg-video-armsoc
xserver-xorg-video-armsoc:
  Installed: 0.0+git20121019+rebdf1e3-0ubuntu2
  Candidate: 0.0+git20121019+rebdf1e3-0ubuntu2
  Version table:
 *** 0.0+git20121019+rebdf1e3-0ubuntu2 0
        500 http://ppa.launchpad.net/hrw/my-own-packages/ubuntu/ raring/main armhf Packages
        100 /var/lib/dpkg/status
rune@chromebook:~$ apt-cache policy chromium-mali-opengles
chromium-mali-opengles:
  Installed: (none)
  Candidate: 0.0+20121110-0ubuntu5
  Version table:
     0.0+20121110-0ubuntu5 0
        500 http://ppa.launchpad.net/hrw/my-own-packages/ubuntu/ raring/main armhf Packages

Not sure w...

Read more...

Tom Townsend (tom-towny) wrote :

Found some interesting data with regards to FPS when testing things for graphics acceleration.

Running "glxgears" on Ubuntu 13.04 in Unity gives me around 15fps. This is just with 2 windows open (the rotating gears and the terminal)

What's strange is that when I move the terminal window around I see jumps to around 30fps. Surely increasing the work on the GPU would mean we'd expect a drop in framerate?

Tom Townsend (tom-towny) wrote :

Also if you run "glxinfo -info" it returns the renderer as Software Rasterizer rather than Mali-T604 that is reported in "unity-support-test"

Rune K. Svendsen (runeks) wrote :

Please disregard my comment #39. I seem to had messed up my installation. Re-installed and I'm back to working OpenGL ES but non-accelerated Xorg.

Tom, as far as I know, glxgears runs in software mode because there is no GLX implementation on OpenGL ES hardware. There is, however, a gears implementation that runs using EGL and it's called es2gears. This is in the package mesa-utils-extra. This also contains the EGL-version of glxinfo - es2_info.

Tom Townsend (tom-towny) wrote :

Rune, cheers I wasn't aware that was the case. Still weird that the software rendering of the gears actually got better under load.

Rune K. Svendsen (runeks) wrote :

Wrt. to the bug, it seems the reason that X acceleration doesn't work under Ubuntu is that it doesn't work under Chrome either. Chrome doesn't use EXA (there's no mention of EXA in Chrome OS' Xorg.0.log). It seems that the nice effects in Chrome OS are achieved by simply creating a full screen OpenGL ES application that contains the background, panel and all the windows, completely circumventing the need for EXA.

jv13613 (jv13613) wrote :

I was able to extract a 13mb file from a graphics binary for the Nexus 10, which also uses the Mali 604. It is named libGLES_mali.so. From what I can tell your current chromium-mali-opengles does not include this. Even though the package contains libGLESv2_mali.so, it is a very small file. Could libGLES_mali.so help at all? Link to graphics download: https://developers.google.com/android/nexus/drivers#mantajop40c

Tom Townsend (tom-towny) wrote :

Rune: is this not EXA working under ChromeOS?

[ 3.989] (II) ARMSOC(0): Soft EXA mode
[ 3.989] (II) EXA(0): Driver allocated offscreen pixmaps
[ 3.989] (II) EXA(0): Driver registered support for the following operations:
[ 3.989] (II) Solid
[ 3.989] (II) Copy
[ 3.989] (II) Composite (RENDER acceleration)
[ 3.989] (II) ARMSOC(0): [DRI2] Setup complete
[ 3.989] (II) ARMSOC(0): [DRI2] DRI driver: armsoc
[ 3.989] (==) ARMSOC(0): Backing store disabled
[ 3.989] (==) ARMSOC(0): Silken mouse enabled
[ 3.989] (II) ARMSOC(0): HW cursor initialized
[ 3.998] (II) ARMSOC(0): RandR 1.2 enabled, ignore the following RandR disabled message.
[ 3.998] (==) ARMSOC(0): DPMS enabled
[ 4.061] (--) RandR disabled
[ 4.062] (II) Initializing built-in extension Generic Event Extension
[ 4.062] (II) Initializing built-in extension SHAPE
[ 4.062] (II) Initializing built-in extension MIT-SHM
[ 4.062] (II) Initializing built-in extension XInputExtension
[ 4.062] (II) Initializing built-in extension XTEST
[ 4.062] (II) Initializing built-in extension BIG-REQUESTS
[ 4.062] (II) Initializing built-in extension SYNC
[ 4.062] (II) Initializing built-in extension XKEYBOARD
[ 4.062] (II) Initializing built-in extension XC-MISC
[ 4.062] (II) Initializing built-in extension XFIXES
[ 4.062] (II) Initializing built-in extension RENDER
[ 4.062] (II) Initializing built-in extension RANDR
[ 4.062] (II) Initializing built-in extension COMPOSITE
[ 4.062] (II) Initializing built-in extension DAMAGE
[ 4.062] (II) ARMSOC(0): Setting screen physical size to 361 x 203

Also I found swrast_dri.so in "/usr/lib/dri" which may or may not be useful.

Rune K. Svendsen (runeks) wrote :

Tom, yes it is. My current understanding of the situation is that Google has developed the DDX driver (xserver-xorg-video-armsoc) to be optimized for OpenGL content, which uses DRI2. This causes non-DRI2 buffers to be allocated in the same way as DRI2 buffers, which slows down 2D content, which doesn't use DRI2.

Siarhei Siamashka explains this in the comments to the following YouTube video: http://www.youtube.com/watch?v=Vzmckw3fAQo

Jan Rinze (janrinze) wrote :

finally some success:

with latest kernel chromeos-3.4 and mali 0.45 i have a glmark2-es score of 20 in Xubuntu. (unity or gnome fail)
reading up here it was a nice surprise to see that XFCE will now do a score of 99 !!
Full screen glmark2-es does a score of 55 :-)

I have turned off vsync to see get the fastest results. (with vsync on it will be a score of 97)

Only bummer is that when a screensaver kicks in the device becomes unresponsive and i need to reboot.
So disabling all screen powermanagement and screensavers is the best option for now.

Jan Rinze (janrinze) wrote :

forgot to mention that the window decorations are all broken in XFCE. I need to figure out what causes that.
Also kernel chromeos-3.8 breaks font rendering in X which i need to investigate too.
that same kernel shows a glmark-es2 score of 68.. so there is some regression in that kernel.

Have you tried raring or saucy?

2013/6/3 Jan Rinze <email address hidden>

> forgot to mention that the window decorations are all broken in XFCE. I
> need to figure out what causes that.
> Also kernel chromeos-3.8 breaks font rendering in X which i need to
> investigate too.
> that same kernel shows a glmark-es2 score of 68.. so there is some
> regression in that kernel.
>
> --
> You received this bug notification because you are subscribed to Cross
> distro support for Samsung Chromebook (ARM based).
> Matching subscriptions: chromebook-arm bug tracker
> https://bugs.launchpad.net/bugs/1085596
>
> Title:
> Graphics acceleration not working in ubuntu desktop 12.10
>
> Status in Cross distro support for Samsung Chromebook (ARM based):
> Confirmed
>
> Bug description:
> No visible graphics acceleration in ubuntu 12.10 (unity,compiz)
>
> Installed:
>
> xserver-xorg-video-armsoc == accelerated Xorg video driver.
> chromium-mali-opengles == OpenGL ES support
>
> Copied exynos.conf to from chromeO to Subuntu system
>
> Hardware acceleration defaults to software rendering.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/chromebook-arm/+bug/1085596/+subscriptions
>

Jan Rinze (janrinze) wrote :

The results are with raring.
I first tried Debian 7 and Sid but they won't give a working gles environment
Even got some webgl demos working now on chromium browser.
Apparently the armsoc driver is quite picky about the kernel and the distro.

Changed in chromebook-arm:
status: Confirmed → Fix Released

Jan Rinze,

Which version of the driver are you running, what kernel, and can you post your exynos.conf ???

Chris W (chrsw) wrote :

I'm trying to get a Mali OpenGL ES environment up and running on my Linux Chromebook. I appear to be stuck. Are there a streamlined set of steps to get this up and running? Right now I'm running Ubuntu 13.04 (Xubuntu) but I'm open to running different Ubuntu flavors or Linux distros to achieve this.

http://malideveloper.arm.com/develop-for-mali/features/graphics-and-compute-development-on-samsung-chromebook/

I haven't had much luck with the 3.8 kernel-next kernel on 13.04 either yet...

You just need to change /dev/mali0 file mode to 777

Add this rule to your udev rules, and opengl es 3.0 now works for me :

KERNEL==”mali[0-9]”, GROUP=”video” MODE=”0777”

> http://malideveloper.arm.com/develop-for-mali/features/graphics-and-compute-development-on-samsung-chromebook/
>
> I haven't had much luck with the 3.8 kernel-next kernel on 13.04 either yet...

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers