Google Swiftly Sneaks Swiffy By Us

Yesterday many people may have missed a major announcement by Google amid all the hubbub of the Google Plus launch, Swiffy.Google: “Swiffy converts Flash SWF files to HTML5, allowing you to reuse Flash content on devices without a Flash player (such as iPhones and iPads).

Swiffy currently supports a subset of SWF 8 and ActionScript 2.0, and the output works in all Webkit browsers such as Chrome and Mobile Safari.”

Now I’ve never been much of a Flash person (in fact I can’t stand it) but I do admit motion graphics have their place on a website and can be as eye catching and mesmerizing as a snake charmers flute to a snake.

Take a look at some of the examples:

Swiffy

Google Chrome ad
File sizes (gzipped): SWF: 34.2 KB, HTML: 37.5 KB
Google Chrome ad using various SWF features such as vector graphics, embedded fonts and timeline animation.

Symphony Orchestra ad
File sizes (gzipped): SWF: 29.0 KB, HTML: 29.5 KB
An example using masks. This shows Swiffy’s graceful degradation when an unsupported feature is encountered (in this example, a drop shadow filter).

Game example 1
File sizes (gzipped): SWF: 5.0 KB, HTML: 5.9 KB
A simple AcionScript 2.0 game with support for keyboard and mouse input.

Game example 2
File sizes (gzipped): SWF: 1.1 KB, HTML: 1.8 KB
Another simple game supporting mouse and touch input.

As you can see the final HTML5 files are slightly larger than the original SWF files but since most of the SWF files are only a few kilobytes in size, it shouldn’t slow the users browser down very much when compared to downloading a large FLV file.

Unfortunately Swiffy uses SVG features that are currently only supported by Webkit-based browsers such as Safari (on desktop and mobile) and Chrome. That means Firefox and IE (yes even IE9) users are out in the cold but, if you’re making a project for a mobile device you shouldn’t have any issues since the most popular mobiles are Android devices running Chrome or iDevices running Webkit. If you really want to use this on your website you could simply browser sniff with a bit of JavaScript and load a static image if it’s not a webkit based browser.

For more information and to try it out yourself with an Flash5 SWF file visit: swiffy.googlelabs.com