如何在flex 3中嵌入音频? [英] how to embed audio in flex 3?

查看:86
本文介绍了如何在flex 3中嵌入音频?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想在用户单击flex 3中的按钮时播放声音.我的flex应用程序将一张一张地生成图像.对于每张图像,背景应有一种声音.有任何想法吗?预先感谢

i want to play a sound when user click on the button in flex 3. My flex application will generate the images one by one. For each image, one sound should come in background. Any ideas? thanks in advance

推荐答案

您应该可以编写如下内容:

You should be able to write something like this:

[Embed(source="myfile.mp3")]
[Bindable] //Not required. Just an example of using multiple meta tags.  
public var soundCls:Class;

这将使您能够通过类名引用文件

This will give you the ability to reference the file via the class name

这篇关于如何在flex 3中嵌入音频?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆