News

Is WebGL the saviour of the mobile web?

The Away Foundation’s director, Rob Bateman, explains how the graphics API can be utilised to push mobile to the next level

RobBateman

The Away Foundation’s director, Rob Bateman, explains how the graphics API can be utilised to push mobile to the next level

RobBateman

ROB BATEMAN – Director of The Away Foundation

A common dilemma for the mobile marketer is whether to create an app or a website. Do you go with a single-codebase webpage or a bespoke, native application, written for as many platforms as your budget will allow to distribute and maintain on app stores?

At face value this seems ludicrous, given the effort and cost involved. But the latter option has frequently won out because of a major hurdle facing browsing experiences to date: performance. The modern mobile browser has suffered a major disadvantage in performance over native applications.

HTML was already a highly complex stack of visual elements when it arrived on mobile, and despite improvements in the run-time execution speeds of JavaScript, the visual compositing and animation of mobile web browsers lags behind native apps. As a result, most web content created for mobile is static, text-heavy content; great for reading news articles, but hardly the platform of choice for engaging applications.
The steady advance in mobile hardware has paved the way for better performance, with a noticeable effect on what is possible in the browser without closing the gap between native and web.


WebGL is rapidly becoming the best choice for high-performance cross-platform web apps that require the fast graphics capabilities of a native application.


The problem is only set to get worse. To increase hardware performance, more focus is being placed on the graphics processing unit (GPU), which offers higher speeds from parallel processing data. The architecture of the GPU enables this to occur with less energy – an important statistic in the world of constrained mobile power requirements.This is great for native applications, but creates a problem for browsers which tend to favour the CPU for most tasks, including a large part of the built-in graphics pipeline.

To break the mobile browser out of its CPU shackles, a new graphics API was required. This was the requirement that brought into being WebGL – an open standard. Its management and development is not controlled by the W3C, but by Khronos Group, a consortium of commercial companies with interests in advancing open standards in rich media APIs such as OpenGL. WebGL has rapidly become a standard that browser vendors feel is worth implementing, including all the major desktop browser vendors and the larger handset vendors including Apple, Google and Microsoft.

WebGL is rapidly becoming the best choice for high-performance cross-platform web apps that require the fast graphics capabilities of a native application. So what practical application does WebGL hold for mobile browsers? One obvious area is in games, where fast-paced motion graphics are required. Responsive user interfaces also stand to benefit as new, real-time interactions are dreamt up that before could only have been done piecemeal. Perhaps most ground-breaking is the field of interactive data visualisation. 

When describing large data sets, nothing says it like you mean it more than an infographic. They convey meaning on a macroscopic scale, enabling data to be revealed and consumed naturally. The design process involves a balancing act between clarity and aggregation, and one way to enhance the experience is by graphically interacting with the data so that areas of interest can be explored. WebGL now not only makes this possible, but easily accessible across devices.

As a recent example of interactive data visualisation, open source companies, The Away Foundation collaborated with 51degrees.com to build a proof of concept. With the amount of momentum behind the WebGL standard, we are now on the verge of significantly reducing the performance gap between the browser and native run-times on mobile. Combined with the browser’s unflinching promise of cross-platform authoring, cost-free publishing and frictionless distribution, this might just be enough to tip the balance in favour of browser-only apps for mobile developers. It should give the app stores plenty to think about when considering the mobile app landscape of the future, and their role within it.

×