Run WebGL in Chromium Browser on PandaBoard


These are the steps to get up and running

  1. Install Ubuntu for OMAP4 on an SD card
  2. Boot from SD card and complete setup
  3. Install ubuntu-omap4-extras-graphics packages from the repository ppa:tiomap-dev/release
  4. Install chromium-browser package, version 10.0.648.205 is installed
  5. Reboot
  6. Run chromium-browser with the --use-gl=egl command line switch. The about:gpu page should show that a GPU is present. You can use a GPU accelerated canvas by opening page about:flags and setting GPU Accelerated Canvas 2D to enabled.
  7. Point to a site that has WebGL demos e.g. three.js
That’s all folks!

4 thoughts on “Run WebGL in Chromium Browser on PandaBoard

  1. Hi,
    Can you specify what build of chromium-browser did you use ? the latest version doesn’t seem to recognize the gpu acceleration. Thanks.

    1. I updated step 3. Installing ubuntu-omap4-extras-graphics package pulls in ubuntu-omap4-extras, the contrary is not true. That may be the reason GPU acceleration did not work for you.

  2. Hi Devendra,

    For some reason it never worked. I started again from scratch using the headless image. It works well now. Here is what I did :

    # download and install http://cdimage.ubuntu.com/releases/11.04/release/ubuntu-11.04-preinstalled-headless-armel+omap4.img.gz (You’ll need a serial tty for the installation)

    # once logged in
    sudo apt-get install python-software-properties
    sudo add-apt-repository ppa:tiomap-dev/release
    sudo apt-get update
    sudo apt-get install xserver-xorg xserver-xorg-core xinit
    sudo apt-get install ubuntu-omap4-extras
    sudo reboot

    # chromium wants to load ‘libEGL.so’, for some reason the simlink doesn’t exists.
    sudo ln -s /usr/lib/libEGL.so.1 /usr/lib/libEGL.so

    # same for libGLESv2.so
    sudo ln -s /usr/lib/libGLESv2.so.1 /usr/lib/libGLESv2.so

    # create a xinitrc file
    echo ”
    #!/usr/bin/bash
    chromium-browser –use-gl=egl
    ” > ~/.xinitrc
    chmod +x ~/.xinitrc

    # for some other reason, chromium only see my gpu when started with super privileges (permission issue?)
    sudo startx

    # go to about:gpu, you shoud see some infos
    # go to about:flags and enable accelerated compositing + canvas. saving will restart chrome
    # go to http://alteredqualia.com/three/examples/webgl_skull.html. If you see a skull, it works

    # it shoud work the same way on the desktop 11.04 preinstalled image except you don’t need the xorg/xinitrc/startx stuff

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s