【问题标题】:Targeting Flash Player 10.3 in Adobe Flash CS5在 Adob​​e Flash CS5 中以 Flash Player 10.3 为目标
【发布时间】:2011-08-14 16:23:48
【问题描述】:

有没有人成功尝试在 Adob​​e Flash CS5 中使用 Microphone.getEnhancedMicrophone() 方法?

我尝试了所有这些步骤;

Step 1: Go to the locaiton C:\Program Files\Adobe\Adobe Flash CS5\Common\Configuration\ActionScript 3.0
Step 2: Create a new folder with the name "FP10.3"
Step 3: Copy the file and paste it in the following location:
            C:\Program Files\Adobe\Adobe Flash CS5\Common\Configuration\ActionScript 3.0\FP10.3
Step4: Rename the swc name to "playerglobal.swc"

Step 5: Goto the following location C:\Program Files\Adobe\Adobe Flash CS5\Common\Configuration\Players
Step 6: Create a copy of "FlashPlayer10_1.xml" and rename as "FlashPlayer10_3.xml"
Step 7: Open it in an editor and change according to below:
             <player id="FlashPlayer10.3" version="12" asversion="3">
   <name>Flash Player 10.3</name>
   <path builtin="true"/>
   <path platform="WIN">Device Central/adcdl.exe</path>
   <path platform="MAC">Device Central/adcdl</path>
   <playerDefinitionPath as2="$(UserConfig)/Classes/FP10;$(UserConfig)/Classes/FP9;$(UserConfi g)/Classes/FP8;$(UserConfig)/Classes/FP7" as3="$(AppConfig)/ActionScript 3.0/FP10.3/playerglobal.swc" />

Step 8: Close the flash application if launched and restart the flash application.
Step 9: If you promptly followed everything you will Flash player 10.3 in the target players from the publish settings and change your target to flash player 10.3.
Step 10: Now import two statements:

          import flash.media.Microphone;
          import flash.media.MicrophoneEnhancedMode;

然而,现在当我尝试调用 Microphone.getEnhancedMicrophone() 函数时,我收到一个错误 - TypeError: Error #1006: getEnhancedMicrophone is not a function

在谷歌上搜索了一下后,我发现我需要使用-swf-version=12 作为参数来编译它,但这似乎适用于 flex,我不知道它如何适用于 Flash CS5。

任何帮助将不胜感激。

谢谢

【问题讨论】:

    标签: flash actionscript-3 flash-cs5


    【解决方案1】:

    不久前我在使用 Player 10.1 迁移到 Flash Professional CS4 时遇到了类似的问题:Flash Player 10.1 for Flash Professional CS4 playerglobal.swc?

    您是否正在使用“测试电影”编译您的程序?请尝试“调试电影”。

    Test Movie 使用内置的 Flash 播放器(或者它至少曾经这样做过),遗憾的是,它是不可更新的。您可以通过使用 Test Movie 运行以下命令来确定它的版本:

    import flash.system.Capabilities;
    
    trace(Capabilities.version);
    

    Debug Movie 将使用位于您的FlashCS5 &gt; Players 文件夹中的调试播放器编译并启动您的项目,并且由于该目标播放器是 10.3,您应该不会再收到错误。

    【讨论】:

    • 酷。谢谢。那么,当我发布它并在浏览器中查看它时,它应该可以正常工作吗?
    • 是的,但您仍然可以使用“调试影片”(Command + Shift + Return)或在独立的 Flash Player 中发布和运行您的 .swf 进行测试
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-08-04
    • 2017-03-19
    • 2011-12-01
    • 2013-08-16
    • 2012-03-07
    • 1970-01-01
    相关资源
    最近更新 更多