My core libraries on GitHub
Gary McGhee - Friday, September 18, 2009
I finally got my core libraries up on GitHub
Flash on the iPhone hypothetical solution
Gary McGhee - Monday, November 10, 2008
It seems to me it would be possible to get Flash applications working on the iPhone now, without Adobe or Apple's cooperation.
Flash and Air apps are distributed as swf or air files containing bytecode for the Adobe Virtual Machine 2 (AVM2) (documented here) calling its APIs for graphics, window management, file system etc, and so the challenge is to execute that bytecode andimplement those libraries. iPhone apps are written in Objective C with some subset of the MacOS X libraries, and some new ones.
So my proposal is :
Flash and Air apps are distributed as swf or air files containing bytecode for the Adobe Virtual Machine 2 (AVM2) (documented here) calling its APIs for graphics, window management, file system etc, and so the challenge is to execute that bytecode andimplement those libraries. iPhone apps are written in Objective C with some subset of the MacOS X libraries, and some new ones.
So my proposal is :
- write a translator from AVM2 bytecode to Objective C. This kind of thing has been done many times before. HotRuby takes Ruby bytecode output from the Ruby interpreter and translates to AVM2 to run a Ruby program on the Flash player.
- Implement the Flash and/or Air system calls (eg. play a sound, create a window, open a file) in Objective C and OS X libraries.
- Write a compiler to take a .air or .swf file and convert its code and assets into a form useable in Objective C/OS X.
- Output a fully native iPhone app, ready for upload to Apple. They don't even need to know it was written in Flash/Flex!
- Apple wouldn't like it. You might even find your name blacklisted in the OS X EULA !
- Adobe might be OK with it. They get more Flex customers, and you become the bad guy (not them) in Apple's eyes.
1
Recent Posts
- SOLUTION: gemcutter "gem migrate" gives "Too many authentication failures"
- SOLUTION: svn: Can't open file '.svn/text-base/somefile.ext.svn-base': No such file or directory
- My core libraries on GitHub
- Flex child components that don't interfere with mouse events
- Pure Actionscript HTML Parser (with thanks to John Resig)
- "svn: No repository found" error with svn+ssh on the same host
- Don't underestimate Radiant CMS
- Hello Magento
- Closet JRubists article
- Flash on the iPhone hypothetical solution
Tags
Flash gems Objective C iPhone subversion solution JRuby Ruby gemcutter Radiant Rails AVM2 CMS Magento


Comments
Post has no comments.