iPhone 录音并导出/通过电子邮件发送
我搜索了苹果网站、互联网以及 Stackoverflow。有谁有任何示例代码或教程,说明如何从内置麦克风录制音频,然后通过电子邮件导出该音频?拜托,我的应用程序确实需要它。谢谢。
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
我搜索了苹果网站、互联网以及 Stackoverflow。有谁有任何示例代码或教程,说明如何从内置麦克风录制音频,然后通过电子邮件导出该音频?拜托,我的应用程序确实需要它。谢谢。
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
接受
或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
发布评论
评论(1)
我使用 Apple 的 SpeakHere 示例应用程序中的代码将声音从内置麦克风录制到 wav 文件“recordedFile.wav”,然后将以下方法添加到视图控制器以通过电子邮件将 wav 文件作为附件发送
:从按钮获取 IBOutlet 方法。不要忘记在头文件中将控制器声明为 MFMailComposeViewControllerDelegate。
I used code from Apple's SpeakHere example app to record sound from the built-in mic to the wav file "recordedFile.wav", then added the following methods to the view controller to email the wav file as an attachment:
You can make the mailAttachedWavFile method an IBOutlet from a button. Don't forget to declare the controller as a MFMailComposeViewControllerDelegate in the header file.