我们如何在 iPhone 中实现无线电闹钟?
我想将闹钟声音设置为 iPhone 中我的应用程序的选定无线电流。 如果有人知道这一点请帮助我。
提前致谢
I want to set alarm sound as selected radio streams for my app in iphone.
If any one knows this please help me.
THANKS in advance
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
您可以安排本地通知(警报),其功能与“推送通知”非常相似。将显示一个对话框,也可以播放静态声音文件。如果用户单击对话框中的“查看”,您的应用程序将打开,您可以开始运行代码(即加载音频流)。
所以不,实际上不可能从网络加载音频流。当您在后台时,您可以继续流式传输,但无法开始流式传输。
如果您的应用程序位于前台并且屏幕刚刚锁定,您也许可以执行此操作。但如果他们离开你的应用程序,它就不起作用了。
You can schedule a local notification (alarm) that functions very similar to a "push notification". A dialog will be displayed, a static sound file can be played as well. If the user clicks "view" in the dialog, your app will open and you can start running code (i.e. load an audio stream).
So no, it's not really possible to load an audio stream from the network. You can KEEP streaming when you're in the background, but you can't START streaming.
You might be able to do it if your app was in the foreground, and the screen was just locked. But it wouldn't work if they left your app.