如何从一个基于JavaScript web应用程序的一个记录声音?

问题描述:

我试图写一个web应用程序,它记录的WAV文件(如:从用户的麦克风)。我了解Javascript不能单独做到这一点,但我感兴趣的是最少的专有方法来增加我的Javascript。我有针对性的浏览器是火狐PC和Mac(所以没有的ActiveX)。请分享这您的经验。我收集它可以用Flash来完成(而不是作为一个格式化的WAV文件)。我收集它可以使用Java来完成(但并非没有code签名)。这些是唯一的选择?

I'm trying to write a web-app that records WAV files (eg: from the user's microphone). I know Javascript alone can not do this, but I'm interested in the least proprietary method to augment my Javascript with. My targeted browsers are Firefox for PC and Mac (so no ActiveX). Please share your experiences with this. I gather it can be done with Flash (but not as a WAV formated file). I gather it can be done with Java (but not without code-signing). Are these the only options?

@dominic-mazzoni我想文件记录为WAV,因为,因为Web应用程序的目的是要组装的的优质短soundbites库。我估计上传的将是50 MB,这是非常值得的质量。该应用程序将只在我们的内联网使用。

@dominic-mazzoni I'd like to record the file as a WAV because because the purpose of the webapp will be to assemble a library of good quality short soundbites. I estimate upload will be 50 MB, which is well worth it for the quality. The app will only be used on our intranet.

更新:现在有一个替代的解决方案感谢JETPACK即将推出的音频API:请参见https://wiki.mozilla.org/Labs/Jetpack/JEP/18

UPDATE: There's now an alternate solution thanks to JetPack's upcoming Audio API: See https://wiki.mozilla.org/Labs/Jetpack/JEP/18

闪存您需要使用媒体服务器(注:我仍然在使用Flash MX,但快速谷歌搜索带来了为Flash CS3文档,似乎同意 - 注意,闪存CS4是很快出来了,可能会改变的话)。 Macromedia公司/使用Adobe的目标是鞭打你的媒体服务器,但是Red5的开源项目可能是suitible为您的项目:

Flash requires you to use a media server (note: I'm still using Flash MX, but a quick Google search brings up documentation for Flash CS3 that seems to concur - note that Flash CS4 is out soon, might change then). Macromedia / Adobe aim to flog you their media server, but the Red5 open-source project might be suitible for your project:

http://osflash.org/red5

我认为Java将是更suitible。我见过一个applet,也许你想在什么上的Moodle(一个开源的虚拟学习环境):

I think Java is going to be more suitible. I've seen an applet that might do what you want over on Moodle (an open-source virtual learning environment):

http://64.233.183.104/search?q=cache:k27rcY8QNWoJ:moodle.org/mod/forum/discuss.php%3Fd%3D51231+moodlespeex&hl=en&ct=clnk&cd=1&gl=uk

(会员要求的网站,但开放给谷歌,因此链接去谷歌的缓存页)。

(membership-required site, but open to Google, hence the link goes to the Google cache page).