swfmillで生成したxmlをひも解いてみる シンプル編
swfmillはswfをxmlに変換することができます。
そのxmlを見てみることにした。
使用したのはcs5。swfmillのバージョンは0.2.12
とりあえずパブリッシュしただけのものをxml化してみた。
サイズは240x300、フレームレートは12、背景色は白
以下が全文
<?xml version="1.0" encoding="UTF-8"?> <swf version="10" compressed="1"> <Header framerate="12" frames="1"> <size> <Rectangle left="0" right="4800" top="0" bottom="6000"/> </size> <tags> <FileAttributes hasMetaData="1" useNetwork="0"/> <Metadata> (metadata) </Metadata> <SetBackgroundColor> <color> <Color red="255" green="255" blue="255"/> </color> </SetBackgroundColor> <ShowFrame/> <End/> </tags> </Header> </swf>
flashplayerのバージョンとムービーの圧縮です。1で圧縮、0で非圧縮です
<swf version="10" compressed="1">
フレームレートと総フレーム数です
<Header framerate="12" frames="1">
ステージの大きさです、なぜか数字は20倍。
<size> <Rectangle left="0" right="4800" top="0" bottom="6000"/> </size>
この中に実際の情報が入っていきます
<tags></tags>
ファイル情報が入ります。
<FileAttributes hasMetaData="1" useNetwork="0"/>
メタデータが入ります。中身はRDFなどで書かれ、descriptionやCreateTool、CreateDateが入ります
<Metadata></Metadata>
背景色です。今回は白なので全部255
<SetBackgroundColor> <color> <Color red="255" green="255" blue="255"/> </color> </SetBackgroundColor>
フレームの区切りとフレーム終了です
<ShowFrame/> <End/>