Every tag starts with a record header whose top 10 bits are the tag code. This is every code from 0 to 93. The SWF column is the version that introduced the tag, as the specification gives it. The tags of SWF 1 to 5 belong to this format; the later ones are listed too, since a movie may hold them, and the explorer still reads them.
All tag codes
Tags marked † are not in the SWF 19 specification. They occur in real files, written by early Flash, Macromedia Generator and later tools; their names are the ones JPEXS and other tools use, and no source gives a version for them. Codes with no name are not defined by the specification.
| Code | Name | SWF | What it is |
|---|---|---|---|
| 0 | End | 1 | End of the file or of a sprite’s tags |
| 1 | ShowFrame | 1 | Shows the frame and starts the next |
| 2 | DefineShape | 1 | A shape, up to 255 styles of each kind, RGB colours |
| 3 | FreeCharacter † | – | Frees a character (early Flash) |
| 4 | PlaceObject | 1 | Places a character at a depth |
| 5 | RemoveObject | 1 | Removes a character from a depth |
| 6 | DefineBits | 1 | JPEG data whose tables are in JPEGTables |
| 7 | DefineButton | 1 | A button with actions on release |
| 8 | JPEGTables | 1 | The JPEG tables for DefineBits |
| 9 | SetBackgroundColor | 1 | The stage colour |
| 10 | DefineFont | 1 | Glyph outlines |
| 11 | DefineText | 1 | Static text, RGB |
| 12 | DoAction | 3 | Frame actions |
| 13 | DefineFontInfo | 1 | Name, style and codes for DefineFont |
| 14 | DefineSound | 1 | An event sound |
| 15 | StartSound | 1 | Starts or stops a sound |
| 16 | StopSound † | – | Stops all sounds (early Flash) |
| 17 | DefineButtonSound | 2 | Sounds for button state changes |
| 18 | SoundStreamHead | 1 | Format of the streaming sound |
| 19 | SoundStreamBlock | 1 | A frame of streaming sound |
| 20 | DefineBitsLossless | 2 | zlib bitmap, 8, 15 or 24-bit |
| 21 | DefineBitsJPEG2 | 2 | JPEG with its tables |
| 22 | DefineShape2 | 2 | Extended style counts, new styles in records |
| 23 | DefineButtonCxform | 2 | Colour transform for DefineButton |
| 24 | Protect | 2 | Do not import (optional MD5 password from Flash 5) |
| 25 | PathsArePostScript † | – | Marks shapes whose paths follow PostScript fill rules |
| 26 | PlaceObject2 | 3 | Place or modify, with flags |
| 27 | Not defined | ||
| 28 | RemoveObject2 | 3 | Remove by depth |
| 29 | SyncFrame † | – | Early Flash |
| 30 | Not defined | ||
| 31 | FreeAll † | – | Frees every character (early Flash) |
| 32 | DefineShape3 | 3 | RGBA colours |
| 33 | DefineText2 | 3 | Static text, RGBA |
| 34 | DefineButton2 | 3 | Button with condition actions |
| 35 | DefineBitsJPEG3 | 3 | JPEG with zlib alpha |
| 36 | DefineBitsLossless2 | 3 | zlib bitmap with alpha |
| 37 | DefineEditText | 4 | Text field |
| 38 | DefineVideo † | – | An early video definition, never documented |
| 39 | DefineSprite | 3 | Movie clip with its own timeline |
| 40 | NameCharacter † | – | A character’s name (early Flash) |
| 41 | ProductInfo † | – | The compiler that wrote the file (Flex) |
| 42 | DefineTextFormat † | – | Early Flash |
| 43 | FrameLabel | 3 | Frame label |
| 44 | Not defined | ||
| 45 | SoundStreamHead2 | 3 | Streaming sound format, any format |
| 46 | DefineMorphShape | 3 | Morph between two shapes |
| 47 | Not defined | ||
| 48 | DefineFont2 | 3 | Font with codes, name and layout |
| 49 | Not defined | ||
| 50 | Not defined | ||
| 51 | Not defined | ||
| 52 | Not defined | ||
| 53 | Not defined | ||
| 54 | Not defined | ||
| 55 | Not defined | ||
| 56 | ExportAssets | 5 | Names characters for other files and ActionScript |
| 57 | ImportAssets | 5 | Imports characters from another SWF |
| 58 | EnableDebugger | 5 | Debugger password |
| 59 | DoInitAction | 6 | Later: actions run once before a sprite is first used |
| 60 | DefineVideoStream | 6 | Later: a video character. Video is not part of this format |
| 61 | VideoFrame | 6 | Later: a frame of video |
| 62 | DefineFontInfo2 | 6 | Later: FontInfo with a language code |
| 63 | DebugID † | – | A UUID matching the movie to its .swd debug file |
| 64 | EnableDebugger2 | 6 | Later: debugger password |
| 65 | ScriptLimits | 7 | Later: recursion depth and time-out |
| 66 | SetTabIndex | 7 | Later: tab order |
| 67 | Not defined | ||
| 68 | Not defined | ||
| 69 | FileAttributes | 8 | Later: flags for the whole file |
| 70 | PlaceObject3 | 8 | Later: PlaceObject2 with filters, blend mode and more |
| 71 | ImportAssets2 | 8 | Later: ImportAssets for SWF 8 and later |
| 72 | DoABCDefine † | – | Later: ActionScript 3 bytecode with no flags or name. AVM2 is not part of this format |
| 73 | DefineFontAlignZones | 8 | Later: alignment zones for FlashType |
| 74 | CSMTextSettings | 8 | Later: anti-aliasing settings |
| 75 | DefineFont3 | 8 | Later: DefineFont2 at 20 times the resolution |
| 76 | SymbolClass | 9 | Later: links characters to ActionScript 3 classes |
| 77 | Metadata | 1 | XMP (RDF/XML); listed as SWF 1, but it arrived with Flash 8 |
| 78 | DefineScalingGrid | 8 | Later: 9-slice grid |
| 79 | Not defined | ||
| 80 | Not defined | ||
| 81 | Not defined | ||
| 82 | DoABC | 9 | Later: ActionScript 3 bytecode. AVM2 is not part of this format |
| 83 | DefineShape4 | 8 | Later: edge bounds, LINESTYLE2, focal gradients |
| 84 | DefineMorphShape2 | 8 | Later: morph with LINESTYLE2 |
| 85 | Not defined | ||
| 86 | DefineSceneAndFrameLabelData | 9 | Later: scenes and frame labels |
| 87 | DefineBinaryData | 9 | Later: binary data for an ActionScript 3 class |
| 88 | DefineFontName | 9 | Later: font name and copyright |
| 89 | StartSound2 | 9 | Later: starts a sound by class name |
| 90 | DefineBitsJPEG4 | 10 | Later: JPEG3 with a deblocking parameter |
| 91 | DefineFont4 | 10 | Later: CFF font for the Text Layout Framework |
| 92 | Not defined | ||
| 93 | EnableTelemetry | 19 | Later: allows Adobe Scout telemetry |
Other codes
Any other code, including those above 93, is not defined by the specification. JPEXS gives names to a few of the gaps, such as tags of Macromedia Generator and of the authoring tools; those names are not confirmed here. The explorer shows such a tag as “Unknown tag” with its code, and its body as bytes. Its length still lets a reader step over it.
The undocumented and later tags
FreeCharacter (3), StopSound (16), PathsArePostScript (25), SyncFrame (29), FreeAll
(31), DefineVideo (38), NameCharacter (40) and DefineTextFormat (42) come from early
Flash. Their layouts are not documented, and the explorer shows their bodies as
bytes. DebugID (63) is 16 bytes, a UUID that matches a movie to the
.swd debugging file the Flash authoring tool writes beside it.
The tags marked Later belong to SWF 6 and after. A SWF 1 to 5 movie should not hold them; where one does, the explorer reads it as the later formats lay it out. The pages of this format give short notes on most of them, but do not describe the video tags (60, 61) or the ActionScript 3 tags (72, 82), which have no place in a SWF 1 to 5 movie.