Smokescreen - “Flash Player written in Javascript”
- Transfer
I recently saw the topic link Smokescreen - flash to html5 \ js converter , I decided to translate the information that I already read on the network about this new tool. In short: Smokescreen is a new open source project aimed at converting Flash to JavaScript / HTML5 for better interaction with a web page where this was not possible before.
With it, you can expand the support of your project to new platforms without learning new tools, Flash is automatically converted to JavaScript / HTML5. Smokescreen will be released under an open source license and will be distributed free of charge. The cost of support and maintenance will be low so you can make sure that Smokescreen works just the way you need it. The library will give you a wide selection of development tools, including JavaScript development without using ActionScript, and development with Flash connected to the project’s HTML pages.
You are probably familiar with the fact that Adobe Flash does not work on any Apple mobile device. Moreover, it seems that Apple will never allow Flash to run on iPhone / iPod / iPad.
These facts paint a bleak picture for online advertising on mobile devices. Many people still want to use existing Adobe tools to create ads, and replacing these tools with others for a single platform (iPhone / iPod / iPad) looks silly. As an advertising network, we believe that interactive advertising is more attractive than boring static ads, so we had to choose one of the options: live in the dark, in a deserted world of boring mobile ads or do something.
We direct all Smokescreen efforts there as a preliminary right now. In the future, we expect to add support for more Flash features, fix bugs, and improve performance. This is just the beginning. Smokescreen currently supports significant Flash 8 animation capabilities, streaming audio, sound effects, some input features, and basic ActionScript.
Chris Smoak's Smokescreen, “JavaScript Flash Player,” is an incredible thing. It works completely in a browser window, reads SWF files, unpacks them (using pure JS), extracts images and embedded audio files, packs them using base64 and inserts them into data page as data: uri, vector graphics are collected in animated SVG . In the debugger (Chrome Web Inspector) you can see how the SVG changes in real time while playing a demo. Smokescreen even implements its own ActionScript bytecode interpreter. [...] The only thing that bothers me is the performance of the library - it has a volume of 175 KB and more than 8000 lines of code, which can lead to problems on low-power mobile devices.
Demos show Smokescreen in action. Silent demos are compared with their Flash options on the same page. Since Smokescreen is written in JavaScript, it runs slower than the Flash plugin, and speed is limited by browser performance. Until we apply more tricks to increase speed, some demos will not work at a satisfactory speed on the iPad / iPhone / iPod.
Use the latest browser. Smokescreen currently works on Firefox 3.6, Chrome 5, Safari 4, and MobileSafari. There are known issues with Opera 10.5 opera that will be fixed. Doesn't work in IE, even though IE9 looks promising.
In preparing the article, the following resources were used:
Since the library has not yet been officially submitted, there are no links to it (only the pre-release has been announced). In the future, as noted above, the library will be available under an open source license. For informational purposes, you can use the Simon Willison repository , which posted the library code marked:
With it, you can expand the support of your project to new platforms without learning new tools, Flash is automatically converted to JavaScript / HTML5. Smokescreen will be released under an open source license and will be distributed free of charge. The cost of support and maintenance will be low so you can make sure that Smokescreen works just the way you need it. The library will give you a wide selection of development tools, including JavaScript development without using ActionScript, and development with Flash connected to the project’s HTML pages.
Description of the project from the authors
You are probably familiar with the fact that Adobe Flash does not work on any Apple mobile device. Moreover, it seems that Apple will never allow Flash to run on iPhone / iPod / iPad.
These facts paint a bleak picture for online advertising on mobile devices. Many people still want to use existing Adobe tools to create ads, and replacing these tools with others for a single platform (iPhone / iPod / iPad) looks silly. As an advertising network, we believe that interactive advertising is more attractive than boring static ads, so we had to choose one of the options: live in the dark, in a deserted world of boring mobile ads or do something.
We direct all Smokescreen efforts there as a preliminary right now. In the future, we expect to add support for more Flash features, fix bugs, and improve performance. This is just the beginning. Smokescreen currently supports significant Flash 8 animation capabilities, streaming audio, sound effects, some input features, and basic ActionScript.
The principle of the library
Chris Smoak's Smokescreen, “JavaScript Flash Player,” is an incredible thing. It works completely in a browser window, reads SWF files, unpacks them (using pure JS), extracts images and embedded audio files, packs them using base64 and inserts them into data page as data: uri, vector graphics are collected in animated SVG . In the debugger (Chrome Web Inspector) you can see how the SVG changes in real time while playing a demo. Smokescreen even implements its own ActionScript bytecode interpreter. [...] The only thing that bothers me is the performance of the library - it has a volume of 175 KB and more than 8000 lines of code, which can lead to problems on low-power mobile devices.
Demos demonstrating the work of the library
Demos show Smokescreen in action. Silent demos are compared with their Flash options on the same page. Since Smokescreen is written in JavaScript, it runs slower than the Flash plugin, and speed is limited by browser performance. Until we apply more tricks to increase speed, some demos will not work at a satisfactory speed on the iPad / iPhone / iPod.
Use the latest browser. Smokescreen currently works on Firefox 3.6, Chrome 5, Safari 4, and MobileSafari. There are known issues with Opera 10.5 opera that will be fixed. Doesn't work in IE, even though IE9 looks promising.
Swf animated videos displayed with Smokescreen
Demo for Win, Mac, and Linux platforms
Animation banners
Demo for Win, Mac, Linux, iPad, iPhone, and iPod)
Demo for Win, Mac, Linux, and iPad
Smokescreen video on iPad
References
In preparing the article, the following resources were used:
- Official site of the project: smokescreen.us
- A note by Simon Willison on his blog Smokescreen demo: a Flash player in JavaScript (part of the article “Library Operation Principle” )
For those who want to try
Since the library has not yet been officially submitted, there are no links to it (only the pre-release has been announced). In the future, as noted above, the library will be available under an open source license. For informational purposes, you can use the Simon Willison repository , which posted the library code marked:
I uploaded an uncompressed version (the command TextMate Bundles -> JavaScript -> Reformat Selection was used) here: http://gist.github.com/418177
For informational purposes only - the library code is not yet open.