Gaming in Your Browser is About to Get Interesting With WebAssembly
Peter Donnell / 9 years ago
WebAssembly, it may be something that most of you have never really heard of, but it’s going to have a huge impact on the way we use or web browsers. WebAssembly is a compiling technology, which is capable of bringing browser output closer to that of native machine code; not even the best JavaScript compilers come anywhere near it in terms of performance.
Luke Wagner, a Mozilla developer, helped reveal the new additions as Mozilla Hacks this week, while also confirming the availability of WebAssembly ports of Unity’s Angry Bots. The game can now be played on a Chrome, Firefox, Edge and even Safari will be joining the party soon enough.
Below you’ll find a video released by Microsoft that shows the Angry Bots running in Edge using the Chakra engine via WebAssembly.
‘Despite being an early implementation, the demo starts-up significantly faster than just using asm.js as the WebAssembly binaries have a smaller file size and parse more quickly than plain JavaScript that needs to be parsed in the asm.js case.’ said Chakra Program Manager Limin Zhu.
The new format for native web applications supports all the functionality enabled by the asm.js JavaScript subset. Rather than replace Java, it’ll simply expand on what was already possible seamlessly, while allowing more direct access to processor instruction sets, and many other benefits.
‘Two upcoming changes will also significantly improve the developer experience. A standard textual representation of WebAssembly will enable developers to view the source of a WebAssembly binary like any other web script or resource. In addition, the current placeholder Wasm object will be redesigned to provide a more powerful, idiomatic set of methods and properties to instantiate and introspect WebAssembly modules from JavaScript.’ said V8 Java, while announcing their collaboration with WebAssembly.
So what does this mean for most users? Not much in technical terms, but it’s already leading to faster performance, more features and more functionality for or browsers and web applications, which is certainly no bad thing.