• Genome2D编译方法


    Genome2D是一个高效的2D引擎,现在支持Flash(stage3d)和HTML5,因为只有作者一个人在维护,就没开源代码。

    最近和作者沟通了下,已经开源啦。

    作者划分了几个模块,编译起来不是特别方便,这里就简单介绍下Flash的编译方法。

    因为作者把代码转换到haxe上,所以要安装haxe,现在Genome2D的版本是1.0.277,haxe版本3.1.3。

    怎么安装haxe和git就不用讲了吧?一下是本地文件夹和git的对应关系:

    genome2d
        core                 git@github.com:pshtif/Genome2D-Core.git
        context
            flash            git@github.com:pshtif/Genome2D-ContextFlash.git
            common           git@github.com:pshtif/Genome2D-ContextCommon.git
    out

    其中out是输出目录,按照上面的对应关系clone好后,在genome2d目录下,命令行运行haxe coreuildswc.hxml就生成swc,

    不要以为到这里就完成了,因为haxe在链接时,不会链接lib的catalog,所以要用winrar之类的打开swc添加AGAL的catalog,不然会编译报错。

    <script name="com/adobe/utils/extended/AGALMiniAssembler" mod="1407288430000">
                    <def id="com.adobe.utils.extended:AGALMiniAssembler"/>
                    <dep id="Array" type="e"/>
                    <dep id="Boolean" type="s"/>
                    <dep id="Number" type="e"/>
                    <dep id="Object" type="i"/>
                    <dep id="RegExp" type="s"/>
                    <dep id="String" type="s"/>
                    <dep id="flash.display3D:Context3D" type="s"/>
                    <dep id="flash.display3D:Program3D" type="e"/>
                    <dep id="flash.utils:ByteArray" type="s"/>
                    <dep id="flash.utils:Dictionary" type="e"/>
                    <dep id="flash.utils:Endian" type="e"/>
                    <dep id="flash.utils:getTimer" type="e"/>
                    <dep id="int" type="s"/>
                    <dep id="trace" type="e"/>
                    <dep id="uint" type="s"/>
                </script>
          <script name="fl

    如果你要编译HTML5版本的,可自己研究下,比Flash版本的容易。

    最后放上作者的github地址:https://github.com/pshtif,感兴趣的同学可以自己去研究下。

  • 相关阅读:
    状态机的常见问题
    基于quartus的高级时序分析
    FPGA中的时钟域问题
    quartus中的时序约束常用方法
    时序约束与时序分析
    FPGA的PCB设计
    AXI4的主机协议代码分析
    selenium 笔记 场景判断
    Codeforces Round #676 (Div. 2) XORwice、Putting Bricks in the Wall、Palindromifier
    Trap HDU
  • 原文地址:https://www.cnblogs.com/flying_bat/p/3985057.html
Copyright © 2020-2023  润新知