A Page or Symbol stream holds one timeline as a tree of
objects in an MFC archive. The page is
the root; its children are the layers; each layer’s children are its keyframes; and each
keyframe’s children are what is on the stage in it. Every object writes its children
before its own fields, so a reader meets the deepest objects first, and a layer’s name
only after all of its frames.
The layouts here are those of the JPEXS FLA converter, which writes these records for every release. The fields the explorer reads were checked one by one against files from Flash MX 2004 to CS4. Every field is little-endian, and every field marked “from revision n” is present only when the record’s revision byte is at least n; the values of each release are on the Versions page.
The object part
Pages, layers, frames, shapes and instances all start with the same part, the
CPicObj fields:
| Field | Present | Meaning |
|---|---|---|
| u8 | always | The object part’s revision: 2 in Flash MX 2004, 4 in Flash 8, 5 in CS3 and CS4. |
| u8 | always | Flags. |
| objects | always | The children, each with its class tag, ended by 00 00. |
| s32, s32 | revision not 0 | The transformation point, x and y; 0x80000000 when not set. |
| u8 | from revision 3 | Drawing-object flags, as the JPEXS reader names them: non-zero on a shape drawn in Flash 8’s object drawing mode. The single bits are not established. |
| u8 | from revision 4 | Cache as bitmap, the setting Flash 8 introduced. |
| ASCII text ending in 0 | from revision 6 | An identifier; not written by any release of this format. |
Page
The root of the stream, class CPicPage: the object part, whose children
are the layers, then:
| Field | Present | Meaning |
|---|---|---|
| u8 | always | The page record’s revision: 5 in Flash MX 2004, 7 from Flash 8. (Pages kept from older documents can carry 3.) |
| u16 | revision not 4 | The number the next new layer will get. |
| u16 | from revision 5 | The number the next new layer folder will get. |
| u32 | from revision 7 | The current frame, where the playhead was left. |
| u32, then that many pairs of u32 | from revision 3 | The guide points. |
Layer
Class CPicLayer: the object part, whose children are the layer’s
keyframes in order, then:
| Field | Present | Meaning |
|---|---|---|
| u8 | always | The layer record’s revision: 0x0B in Flash MX 2004, 8 and CS3, 0x0D in CS4. |
| CString | always | The layer’s name, such as Layer 1 or [actionscript]; in Unicode form, marked FF FE FF. |
| u8, u8, u8 | from revision 4 | The state as three flags: current, hidden, locked. (Revisions up to 3 had one state byte.) |
| u32 | from revision 5 | The layer’s height; FFFFFFFF seen. |
| u32 | from revision 6 | The outline colour: red, green and blue bytes, then FF. 4F 80 FF FF is #4F80FF. |
| u32 | from revision 6 | Whether the layer is shown as outlines. |
| u32 | from revision 8 | The height multiplier: the layer’s row is shown this many times the normal height. |
| u8 | always | The layer type, below. |
| object | always | The parent: the folder the layer is in, or the mask or guide layer it is masked or guided by, as an object reference; a null tag for none. |
| u8 | from revision 3 | Up to revision 8 a legacy mask flag; from 9, whether a folder is open. |
| u8 | from revision 10 | Whether the name is the automatic one Flash gave it. |
| u8 | revision 13 | The animation type: 0 none, 1 motion object, 2 IK pose. At revision 12 it is not written but taken from the layer type (5 and 6). |
| u32 + u32 values | animation type 2 | A count and the values of an armature layer; not established. |
| Layer type | Meaning |
|---|---|
| 0 | Normal. |
| 1 | Guide. |
| 2 | Guided (a layer drawn along a guide). |
| 3 | Folder. |
| 4 | Mask. |
| 5 | Motion object (CS4). |
| 6 | IK pose, an armature layer (CS4). |
A masked layer is a normal layer whose parent is a mask layer. Revisions 7 and 8 have
a second object after the parent, and revisions 2 to 5 a further u8; neither is written
by a release of this format. The names are the JPEXS converter’s, which maps them to the
layerType words of XFL.
Frame
Class CPicFrame: one keyframe and the frames it lasts for. It starts with
a shape part, because a frame is also the shape drawn directly on the stage in it:
| Field | Present | Meaning |
|---|---|---|
| object part | always | Its children are the instances, text fields and shapes on the stage. |
| u8, 6 × s32, data | always | The rest of the shape part: the shape drawn on the frame itself. |
| u8 | always | The frame record’s revision: 0x17 in Flash MX 2004, 0x18 in Flash 8, 0x1A in CS3, 0x1D in CS4. |
| u16 | always | The duration, in frames. |
| u16 | always | The key mode (a u8 up to revision 2). |
| u16 | from revision 2 | The easing of a tween. |
| u16 | from revision 5 | The sound: the media number of a sound record, 0 for none. |
| u16, then 8 bytes each | from revision 6 | The sound’s envelope points: a u32 position and a u16 level for each channel. |
| u16, u8, u32, u32 | from revision 7 | The sound’s loop count, sync, in point and out point; 0x3FFFFFFF is an unset out point. |
| u16 | from revision 8 | The sound editor’s zoom. |
| CString | from revision 9 | The frame label, empty for none. |
| actions | from revision 4 | Revisions 4 to 9: one action command of Flash 1 to 4. 10 to 18: a u32 count and that many commands. 19 on: the ActionScript block, the frame’s script. |
| u32, u32 | from revision 11 | Motion tween rotation (below) and the number of turns. |
| u32 | from revision 12 | The label type: 0 a name, 1 a comment. |
| object | from revision 13 | The morph shape of a shape tween, or a null tag. |
| u32 | from revision 14 | Shape tween blend: 0 distributive, 1 angular. |
| object | from revision 15 | An object of sound settings, or a null tag. |
| CString | from revision 16 | Not established. |
| u16, 6 × s32, u8, colour transform, u8 | revision 17 only | A block not established, with a matrix and a colour transform. |
| u32 | from revision 20 | Not established. |
| u32 | from revision 21 | The sound effect. |
| u32 | from revision 22 | A bookmark flag, as the JPEXS reader names it; not established further. |
| u32, u32 | from revision 24 | Use one ease curve for all properties; a custom ease follows. |
| 6 × (u32 + points) | custom ease | Six curves, each a u32 count and that many points of six f64. Flash 8’s custom ease has a curve for each of position, rotation, scale, colour and filters, and one for all; the order here is not established. |
| CString, u32 | from revision 27, tween kind 3 | The motion tween as XML, and the keyframes shown. |
| CString | from revision 28, tween kind 3 | The tween’s instance name. |
| u32 + matrices | from revision 29, tween kind 4 | An armature pose: a count, then count × duration matrices of six s32. |
Key mode
The low byte is the tween kind; the bits above it are the tween’s settings.
| Value | Meaning |
|---|---|
| low byte 0 | No tween. |
| low byte 1 | Motion tween (the classic tween of later releases). |
| low byte 2 | Shape tween. |
| low byte 3 | Motion object: the CS4 motion tween, with its XML. |
| low byte 4 | IK pose (CS4). |
0x0100 | Orient to path. |
0x0200 | Scale. |
0x0400 | Rotate. |
0x0800 | Sync. |
0x1000 | Snap. |
0x2000, 0x4000 | Seen in CS4 files (0x2600, 0x5E01); not established. |
0x0600 is the usual value of a frame with no tween in Flash MX 2004 and
Flash 8; Flash CS4 writes 0x2600 (9,728), the same value XFL documents write
as keyMode="9728".
Armatures (CS4 inverse kinematics)
Established from 1 real file: testdata/fla/cs4/0023_inverse_kinematics-cs4-todo.fla
of jindrapetrik/flacomdoc (read
2026-11-13), a CS4 document with one shape armature of 16 bones that poses a figure over
20 frames. A CS4 armature is stored in four places:
- The library symbol of type 5 (an IK container), here named
lsd_1, holds one keyframe per pose frame (20 here), each a plain drawn shape (frame shape revision 5, mode 4) that is the armature’s outline in that pose, with cubic edges. No bone is stored in the shapes. - The layer on the stage (layer animation type 2, “IK pose”) has one
keyframe of the whole duration whose key mode low byte is 4 and whose record ends with
the pose matrices (a count, then count × duration matrices of six s32; see above). It
holds one instance, a
CPicSymbolof the type 5 symbol. - That instance’s persistent data (the property list described under
Contents) holds the bones as
15 named properties. The property value types seen: 1 an array of s32 values, 4 an
array of f64 values, 5 a string. The names and contents:
lsd_frame_data(1; the start frame of each of the three states: 0 9 19, which with durations 9, 10 and 1 fill the 20 frames),lsd_shape_contour_data(5; the outline as<Contour closed="true" data="x,y,x,y,…"/>),ikTreeName(5),lsd(5, the textlsd),_ikTreeXML(5; the three<state duration easeIn easeOut easeType easeValue index name>poses of the XFL_ikTreeStates),lsd_motion_constraints(5; per jointmotionType=rotation|xtrans|ytranswith…Enabled,…Constrained,…Min,…Max),Armature_(5, the armature’s name),lsd_connection_indices(1, 368 values),lsd_world_matrices(5; one<Matrix Name a b c d tx ty/>per node),lsd_node_namesandlsd_bone_names(5; comma lists such asikNode_8,…andikBoneName8,…, seven each),lsd_connections(4, 636 values, a multiple of four),lsd_xdata0andlsd_ydata0(4; one coordinate per node) andlsd_tree(1;4 1 2 3 4 0 0 0 2 5 6 0 0: for each of the seven nodes in turn, a child count followed by the children’s indices, which gives node 0 the children 1 to 4, node 4 the children 5 and 6, and the rest none; this reading is the one that fits the seven nodes, not a published one). - The document’s persistent data (the Contents stream) holds the
tree as the XFL one does:
ikTreeName5_ikTreeStates(the three states, withduration,angle,x,y,xRel,yRel,easeIn,easeOut,easeType,easeValue),Armature_6(a<BridgeTree color displayStyle exportType name startFrame>with its<_ikTreeStates>and a<Nodes>list of<BridgeNode subTreeName subTreeType/>),ikTreeName5_ikStartFrame,ikTreeCount(6),ikBoneCount(16) andikNodeCount(16).
The one node type this file shows is lsd
(subTreeType="lsd", and the property of that name). What it stands for is
not given anywhere; the other types the XFL schema names (ik,
shape, symbol) are not in any binary file read. The
meaning of the lsd_tree, lsd_connections and
lsd_connection_indices arrays is described above only as far as their
shape; the explorer shows them as written.
Sound and rotation codes
| Field | Values |
|---|---|
| Sync | 0 event, 1 start, 2 stop, 3 stream. |
| Effect | 0 none, 1 left channel, 2 right channel, 3 fade left to right, 4 fade right to left, 5 fade in, 6 fade out, 7 custom (the envelope). |
| Rotation | 0 auto, 1 clockwise, 2 counter-clockwise, as the JPEXS reader maps them. The panel’s “none” has no number of its own in that mapping; whether the key mode’s rotate bit is what stores it is not established. |
The frame’s number is not stored. It is 1 plus the durations of the keyframes before it on the same layer.
A Flash 8 keyframe (frame revision 0x18) whose script is
stop(), from the Page 1 stream. The offsets are in the stream,
from the frame record’s revision:
0000024C 18 01 00 00 06 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
0000025E FF FF FF 3F FF FF FF FE FF 00
00000268 04 00 00 00 01 00 00 00 84 67 00 00 00 00 00 00
00000278 FF FE FF 06 73 00 74 00 6F 00 70 00 28 00 29 00 ....s.t.o.p.(.).
stop()18– frame revision0x18: Flash 801 00– a duration of 1 frame;00 06– key mode0x0600- 6 zero bytes – no easing, no sound, no envelope points
- 3 zero bytes – loop count 0 and sync 0; then 4 zero bytes, the in point
FF FF FF 3F– out point not set;FF FF– zoomFF FE FF 00– the label: an empty Unicode CString04 00 00 00– ActionScript block revision 4;01 00 00 00– mode 1, text;84 67 00 00– the identifier;00 00 00 00– no breakpointsFF FE FF 06– a Unicode CString of 6 characters:stop()
Symbol instances
A symbol placed on the stage is a child of the frame it appears in: a
CPicSymbol for a graphic, CPicSprite for a movie clip and
CPicButton for a button. Their fields, with every other object on the
stage, are on the Objects on the
stage page. A movie clip carries an
ActionScript block
with its handlers, and a button one with its on handlers.
The instance name is what ActionScript uses to refer to the instance. The explorer labels each instance’s handlers with that name and the timeline, layer and frame where the instance sits.