Ted Patrick - Demos & MAX @ Adobe Systems


Note: This is the personal blog of Ted Patrick. The opinions and statements voiced here are my own.



SOURCE to 4 Flash iPhone Apps

DIGG IT!     20 Comments Published Monday, October 05, 2009 at 2:10 PM .

Here is the source for 4 iPhone demo applications I made during the internal development of "Notus", aka iPhone export. The projects are ASProject out of Flex Builder. The first thing you will notice is that there is nothing special here, just simple AS3 apps the are cross-compiled to IPA ( iPhone ARM Binaries ).



From these projects you can get started today building apps.

Circles - A simple 2.5D app

Circles GLES - Same app hardware accelerated using GLES

FlashWrap - Bubble wrap with random sounds! (In the Adobe Booth!)

FingerPaint - A simple drawing app (In the Adobe Booth!)

Special thanks from Matt Snow on the UI design in FingerPaint. Also special thanks to the folks at XD for assets.

Have fun, share source, and rock the iPhone!

And yes this is why I haven't been blogging for 3 months!

Cheers,

Ted :)

20 Responses to “SOURCE to 4 Flash iPhone Apps”

  1. # Anonymous iBrent

    Sweet! Thanks for sharing this. In spite of what people may think, it is a good thing that the million+ Flash devs are now iPhone devs, thanks to Adobe. =D  

  2. # Blogger scoobusReadus

    Yes - that is sweet. I see an .ipa file in the Circles app. Any way i can provision this to my iphone? Tells me it's unsigned... so I'm suspecting I can't adhoc this, without the iPhone Dev subscription?

    Thanks! Scott  

  3. # Anonymous Anonymous

    Thanks Ted. Picaso has nothing on you. ;)

    Judah  

  4. # Blogger Doil Lee

    What about Flex to iPhone? Will Flex 4 support iPhone export?  

  5. # Anonymous Chuck

    Impressive! How did you have the time to write this post today? MAX is going great and smoothly so far.  

  6. # Blogger Leviathan2040

    Thanks for the source, it is interesting to understand how it actually happens. I have a couple of questions:

    1) why very simple code like the Circles one generate such huge compiled app considering that there is no runtime or framework attached to it? (I mean 3.7 MB to draw four circles is a lot)

    2) Comparing the Circles example (performing at around 3 frames per second) and CirclesGLES (at least 30 FPS and more) example code seems clear that in order to obtain a decent performance the content has to be mostly static (not regenerated/modified at runtime) and with the CacheAsSurface flag turned on, this reduce a lot the kind of applications that can be made I guess.  

  7. # Blogger Ted Patrick

    These samples were built about 16 builds back and much has changed. Binary size is an issue the team is working on. The swf is translated to LLVM and then grafted with the flash api implemented in native code.

    Ted ;)  

  8. # Blogger Eric Belair

    FingerPaint won't compile in Flex Builder - cannot find flash.events.TouchEvent. Is a specific SDK or Builder version needed?  

  9. # Blogger Kalyan

    This is going to be great, Ted. Thank you!  

  10. # Anonymous James

    There are so many questions to ask about all this, but could you give some info about this...
    flash.media.MediaLibrary
    How's that going to work? What's that going to do when it's running in the standard flash player?

    I was interested in what sort of persistent storage options a Flash iPhone app would have, but I guess that would be the same as any other iPhone app? I haven't done any standard iPhone dev, so I'm not sure what I could expect??  

  11. # Blogger Jompa

    Excellent!
    Did you get copies of the CS5 beta to compile this? Looking forward to start playing around with the touch and accelerometer events :)  

  12. # Blogger Ted Patrick

    Flex on Mobile (iPhone) was demoed in MAX Sneaks by Ely Greenfield.  

  13. # Blogger Ted Patrick

    The builder project requires a very customized SDK to compile. You must have the airglobal.swc configured and there is much work to get this all configured. Early work was done using compilation scripts but this will be automated within Flash Pro and Flash Builder Pro products.

    We used the SDK to get compilation working but ipa export will not be in the SDK when shipping and will be within Flash Pro and Flash Builder( not sure on timeline).

    That is all I know! :)

    Ted :)  

  14. # Blogger Ted Patrick

    flash.media.MediaLibrary allows you to write an BitmapData object into the iPhone Photos app. So you can generate images in you app and push them into Photos on device.

    Ted :)  

  15. # Blogger Ted Patrick

    The goal was for all API's to map to AIR 2.0 or Flash 10.1 APIS. flash.events.TouchEvent was added in both as a native API event type for multi-touch support.

    Ted :)  

  16. # Blogger turbidity

    Hi Ted! Thanks for posting this code. I've got a question about something going on in the FlashWrap application. In the touchBegin function, you're using square bracket notation to turn the touchBegin function into an object and then add properties onto it.
    What's going on there? Is this something specific to iPhone dev, or is this some secret ActionScript mojo I am ignorant of?

    Here's the code in question (from FlashWrap.as):
    public function touchBegin( event:TouchEvent ):void
    { this.touchBegin[ event.touchPointID ] = {}; this.touchBegin[ event.touchPointID ].x = event.stageX; this.touchBegin[ event.touchPointID ].x = event.stageY;
    this.hit( event.stageX , event.stageY );
    }  

  17. # Blogger Ted Patrick

    a Function is an Object so you can put stuff into it just like normal objects. It is ECMA standard but not widely used. The only advantage is that it save 1 Object in your app. This works with all AS3 code.

    Ted :)  

  18. # Blogger Ferenc

    Where can I download the SDK for this ? :-)  

  19. # Anonymous r4 card

    I am waiting for this mobile I am very fond of new phones I loved to use this multimedia and high definition phone these are the My favorite gadgets.They give you very nice performance with sound as well as picture quality and other multimedia  

  20. # Anonymous Anonymous

    Hi Thanks for this.

    Bu can you provide me the links of cs5 availbale or not?  

Post a Comment

Where to find me:

Ted on Twitter - @AdobeTed
Ted on Adobe Groups
Ted on LinkedIn
Ted on Facebook
Ted at Adobe


Latest

Lists

Links

Jobs

Flex Jobs
city, state, zip

Archives