2. Daniel
Sperl
Austria, 1981 Media Design, 1999
Flox, 2012 Gamua, 2009
Starling, 2011 Sparrow, 2010
Photo Play, 2004
iOS Games & Apps, 2009
3. Topics
• Starling 1.5
• Development for Mobile Devices:
• Performance
• Screen Resolutions
• Memory
• Outlook
4. What is Starling?
• A pure AS3 library for Adobe Flash
• Recreates the display list architecture ...
• ... on the GPU (through Stage3D)
• Deploy to:
Browser / Desktop / iOS / Android
A very
talented bird,
if I may say so.
7. Starling 1.5
• Currently Available as Release Candidate
• Includes many internal improvements
• Update highly recommended!
8. Starling 1.5
• Automatic Profile Selection
• More reliable Context Loss handling
• Significantly reduced Start-up Time
• Atlas Textures support Rotation
• SystemUtil class
• …
Features
9. Developing for Mobile
• Limited Performance (GPU + CPU)
• Multiple Resolutions
• Limited Memory
12. Memory
• Mobile Devices have limited RAM
• Mobile Devices have huge Resolutions
• 2D Games need lots of Textures
Watch your Memory Footprint!
13. Memory
Do not Embed Textures
// Avoid:
!
[Embed(source=“assets/textures/hero.png")]
private static var Hero:Class;
!
var texture:Texture = Texture.fromBitmap(new Hero());
• Embedded Textures are in Memory twice:
Class Memory + Texture Memory
• Better: use Starling's AssetManager
14. Memory
Use the AssetManager
var appDir:File = File.applicationDirectory;
var assets:AssetManager = new AssetManager();
assets.enqueue(appDir.resolvePath("assets/textures"));
assets.loadQueue(...);
!
var texture:Texture = assets.getTexture("hero");
• Takes care of Context Loss
• Optimized for minimal Memory Footprint
15. Memory
Use RectangleTextures
// init Starling like this:
!
... = new Starling(Game, stage, null, null, "auto", "auto");
• Standard Textures always allocate MipMaps
• RectangleTextures do not!
• Starling defaults to RectangleTextures
with profiles "baseline" + "baselineExtended"
16. Memory
Use ATF Textures
# Usage example:
png2atf -c -r -i texture.png -o texture.atf
• Stored compressed
in GPU Memory
• Reduced Image Quality
• Easy to create via
Adobe ATF Tools
20. Memory
Summary
• Use the AssetManager
• Use RectangleTextures (profile: auto)
• Use ATF Textures
• Use Bitmap Fonts
• Optimize your Texture Atlases
• Use Adobe Scout
21. Outlook
• Ongoing Support by Adobe
• Collaborating with Adobe
regarding AIR Priorities
• Collaborating with the Starling Community
regarding Starling Priorities
• Flash is not dead™ =)