球滚动音效

发布于 2024-09-11 21:27:23 字数 315 浏览 2 评论 0原文

我正在使用 Chipmunk 和 openAL 为 iPhone 开发一个迷宫风格的应用程序。除了球滚动的声音之外,我一切正常。我尝试的是为球位置的每次更新播放一个小声音,以便整体效果听起来像球在滚动。根据这个论坛上的建议,我厌倦了使用球的速度来调整声音的音高。我有以下问题:

  1. 当我在花栗鼠回调中播放此声音时,我根本听不到声音。我在别处也能听到。
  2. 即使我以某种方式让这个工作正常,我应该播放的声音也必须非常非常短,因为球滚动的时间不会太长。必须有替代方法。

有人可以帮忙吗?如果还包括声音,我什至可以付费购买一个简单的应用程序来执行此操作。

I am working on a Labyrinth style app for iPhone using Chipmunk and openAL. I got everything working except the ball rolling sound. What I have tried is playing a small sound for each update in the ball's position so that the overall effect sounds like the ball is rolling. Based on advice on this forum I tired using velocity of the ball to adjust pitch of the sound. I have the following problems:

  1. I cant hear the sound at all when I am playing this sound in a chipmunk call back. I can hear it elsewhere.
  2. Even if I got this working somehow, the sound I should play has to be very very short as the ball doenst take too long to roll. THere has to be a alternate way.

Can anybody please help? I can even pay for a simple application that did this if the sound is also included.

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

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

发布评论

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

评论(1

烦人精 2024-09-18 21:27:23

我建议作弊...记录(或在某个地方找到)一些球以不同速度滚动的较长循环声音。根据球的速度,让其中之一进行比赛。随着球速的变化,您可以从一个样本交叉淡入淡出到另一个样本。我的猜测是,这听起来比仅仅改变单个样本的音高更真实。

当然,仅仅有一个较长的循环样本就足够了,并且仅改变与球速度成比例的体积。我得去追踪我的迷宫游戏并检查一下。 :)

I recommend cheating... record (or find somewhere) some longish looping sounds of the ball rolling at different speeds. Have one of them playing, based on the speed of the ball. As the ball's speed changes, you can cross-fade from one sample to another. My guess is that that will sound more realistic than just varying the pitch of a single sample.

Of course, it may be enough just to have one longish looping sample, and only vary the volume proportional to the ball's speed. I'll have to go track down my labyrinth game and check. :)

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