Flump reads specially-constructed .fla
and .xfl
files saved by Flash and extracts animations and
textures to allow them to be recreated in the GPU. Animations created in Flump's style will use far
less texture memory per frame of animation than an equivalent flipbook animation, allowing for more
expressive animations on mobile platforms. Runtimes have been written for Starling, Sparrow,
Flambe, PlayN, and StageXL.
.fla
in Flash CS 5, 5.5, or 6.flash.display.Sprite
.flash.display.MovieClip
..fla
and
.swf
files. The .fla
file should appear in the list of source files..fla
file and click 'Preview'. The tween you created in step 6 should start playing
back in a preview window.This walks through Flump's process when it exports a single .fla/.swf file combo.
For each item in the document's library that is exported for ActionScript and extends
flash.display.Sprite
, Flump creates a texture. To do so, it instantiates the library's exported
symbol from the .swf
file and renders it to a bitmap.
All of the created bitmaps for a Flash document are packed into texture atlases, and xml is generated to map between a texture's symbol and its location in the bitmap.
For each item in the document's library that extends flash.display.MovieClip
and isn't a flipbook
(explained below), Flump creates an animation. It checks that for all layers and keyframes, each
used symbol is either a texture, an animation, or a flipbook. Flump animations can only be
constructed from the flump types.
For animations that only contain a few frames, a flipbook may be more appropriate. To create one,
add a new item to the library and name the first layer in the created item flipbook
. When
exporting, flump will create a bitmap for each keyframe in the flipbook layer. In playback, flump
will display those bitmaps at the same timing.
Flump works with Flash CS 5 and later
You will need these dependencies to build Flump:
AIR SDK with Flex Support You'll also need to download the version of the AIR SDK that comes without the new compiler (links near the bottom of that page) and follow the instructions here to overlay it on the Flex SDK
Build the flump runtime
flump/runtime$ ant -Dairsdk.dir=/path/to/air maven-deploy
Build the flump exporter
flump/exporter$ ant -Dflexsdk.dir=/path/to/flex swf
Build the flump demo
flump/demo ant -Dairsdk.dir=/path/to/air
To get AIR to report errors, run Flump with the AIR debugger (adl):
flump/exporter$ /path/to/air/bin/adl etc/airdesc.xml dist
A list of known Flump runtime implementations for different languages and frameworks: