使用 NetStream 以编程方式传输音频

发布于 2024-08-16 23:34:23 字数 310 浏览 4 评论 0原文

在 Flex 中,您可以使用 NetStream.attachAudio,它需要一个 Microphone 对象。是否可以通过 NetStream 从麦克风以外的其他地方传输音频?例如,来自文件/嵌入资源?

我问的原因是我希望能够运行不需要使用实际麦克风的自动化测试。

In Flex you can stream microphone audio to an FMS/Red5 server using NetStream.attachAudio, which requires a Microphone object. Is it possible to stream audio through the NetStream from somewhere other than a Microphone? For example, from a file/embedded resource?

The reason I'm asking is that I'd like to be able to run automated tests that don't require using an actual microphone.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

你的他你的她 2024-08-23 23:34:23

嗯,看来这是不可能的。我的解决方法是使用 SoundFlower 将音频文件播放(在 Flash 外部调用)路由到虚拟麦克风,然后 Flash 流式传输到媒体服务器。从 Flash 的角度来看,这就像您手动对着麦克风讲话一样。

Well, it looks like this isn't possible. My workaround is to use SoundFlower to route audio file playback (invoked outside of Flash) into a virtual microphone, which Flash then streams to the media server. From Flash's point of view, its just as if you were manually speaking into the mic.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文