Thursday, May 26, 2011

Mobile App Development

With a couple mobile apps under my belt on the iPhone, I decided to take the plunge and start porting my primary app to the Android platform.  I probably struggled more with getting the Android SDK environment set up than actually getting the application launched, probably because the setup took me several days to complete and inevitably I would start working on something else while waiting, then lose track of exactly what step I was on. XCode did not come easy for me so I wasn't looking forward to another native SDK for the Android.  I happened to run across a book called Professional Flash Mobile Development which uses Flash Professional CS5 as the development environment with the ability to compile the project for iOS or Android.  That's a huge plus to learn a single platform that can compile the app to different mobile devices.  I gave it a try and with the help of this video tutorial about ActionScript 3 programming, I was up and running in a weekend and a working prototype assembled within the week and an app in the Android market in 3 weeks.  By comparison, my first iPhone app took months to complete.  I attribute the difference to better learning tools (like the videos) and a huge group of Adobe Flash users that had already posted answers to just about every question I would have along the way.  My app has uses about 45 Adobe Illustrator files and the majority of my time was spent trying to figure out how to get the Illustrator files to work inside Flash.  There are several different options, like saving to a bitmap, importing the AI file into the library/stage, using a load class to load dynamically.  Each of these options worked okay, but the best solution I found was much more subtle.  To preserve the vector artwork, importing into the library worked great until I had imported about 20 files, then I started getting really weird errors "5005: Unknown Error optimizing byte code" in my AS3 code that didn't make any sense because I wasn't updating any AS3 code, I was just importing AI files.  After reading through several dozen posts and solutions that didn't work for me, I found out that Adobe Illustrator can export files to SWF, while still preserving the vector based artwork, plus the code worked exactly the same as importing the AI file, not to mention the exported files were much smaller.

If you would like to know more about my apps, please check out www.SmartLittleKid.com

No comments:

Post a Comment