iPhone AVAudioPlayer循环卡死了吗? [英] iPhone AVAudioPlayer loop stuttering?

查看:78
本文介绍了iPhone AVAudioPlayer循环卡死了吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个大约2秒钟长的声音,我将它的numberOfLoops属性设置为-1,但是在两次循环之间有0.5秒的延迟,我希望声音在循环时逐渐消失.请帮忙!

I have a sound that is about 2 seconds long which I have set it's it's numberOfLoops property to -1, but it has a .5 second lag between loops i want the sound to fade into itself when it is looping. Help please!

推荐答案

您可以尝试使用一些低级API来处理声音.在iPhone上使用OpenAL效果很好.理想的循环也很难安静,因为音频文件应该具有例如几乎等效的参数(例如,频率),以使人们从头开始播放文件时不会听到.

You can try to use some low-level API to work with sound.I had good results using OpenAL on the iPhone. Also ideal looping is quiet hard, because your audio file should have, for example almost equivalent parameters(frequency, for example) to make people not to hear when the file is played from the beginning again.

这篇关于iPhone AVAudioPlayer循环卡死了吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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