如何在 FP9 包装文件中使用 Pixel Bender
我们创建嵌入第三方包装 SWF 文件的 Flash 游戏,这些文件导出为 FP9。
如果我创建一个使用 Pixel Bender 类(Shader、ShaderData)的 FP10 SWF,当我在 FP10 播放器内的 FP9 包装器中运行它们时,会抛出错误
VerifyError: Error #1014: Class flash.display::Shader might not be成立。
有没有办法访问这些 FP10 类 - 或者最外层包装器的版本是否决定了子 SWF 可用的内容?这与 applicationDomain 有关吗?
感谢您的帮助, 詹姆斯
We create Flash games which are embedded within third party wrapper SWF files, which are exported for FP9.
If I create an FP10 SWF which uses Pixel Bender classes (Shader, ShaderData), when I run them in an FP9 wrapper within an FP10 player, an error is thrown
VerifyError: Error #1014: Class flash.display::Shader could not be found.
Is there any way to get access to these FP10 classes - or does the version of the outermost wrapper determine what's available to child SWFs? Is this something to do with applicationDomain?
Thanks for any help,
James
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
嗯。我做了类似的事情 - 如果您创建一个包含任何类导入的 SWF 文件,然后从另一个未导入它们的 SWF 文件加载它,您就可以访问这些类。
我不确定是否按照定义(可能会引发编译时错误),但肯定可以获得一个实例(在子 SWF 中定义某些内容,然后通过 MovieClip(theLoader.content).theInstance 访问)。
这里的问题是,本机闪存库可能不包含在内 - 毕竟它们是运行时的一部分。所以 - 尝试实例访问,除此之外,我想不出任何解决方案。
Hm. I did something similar to this - if you make a SWF file with any class import in it, and then load it from another SWF file which doesn't import them, you can access these classes.
I am not sure if by definition (probably would throw compile-time error), but certainly possible to get an instance (define something in the child SWF and then access by MovieClip(theLoader.content).theInstance).
The problem here is the fact that the native flash libraries might not be included - they are a part of the runtime after all. So - try the instance access, other than that, I can not think of any solution.
我在 kirupa.com 上从 senulous 得到了明确的答案 - 不可能在 FP9 包装器中使用 FP10 类
http://www.kirupa.com/forum/showthread.php?t=355224
I got a definitive answer from senocular over at kirupa.com - it's not possible to use FP10 classes within a FP9 wrapper
http://www.kirupa.com/forum/showthread.php?t=355224