UIImagePickerController抛出错误:185:创建聚合音频设备时出错:尝试选择视频时“什么” [英] UIImagePickerController throws ERROR: 185: Error creating aggregate audio device: 'what' when trying to select video
问题描述
当我尝试使用UIImagePickerController从XCode 5的iOS模拟器中的相机胶卷中选择视频时,我得到上述错误。这是输出:
when i try to use UIImagePickerController to select a video from camera roll in the iOS-Simulator of XCode 5, i get the aforementioned error. this is the output:
2013-11-02 21:28:44.788 Imagepicker[89146:1403] 21:28:44.788 ERROR: 185: Error creating aggregate audio device: 'what'
2013-11-02 21:28:44.788 Imagepicker[89146:1403] 21:28:44.788 WARNING: 219: The input device is 0x32; 'AppleHDAEngineInput:1B,0,1,1:2'
2013-11-02 21:28:44.789 Imagepicker[89146:1403] 21:28:44.789 WARNING: 223: The output device is 0x28; 'AppleHDAEngineOutput:1B,0,1,2:0'
2013-11-02 21:28:44.790 Imagepicker[89146:1403] 21:28:44.790 ERROR: 398: error 'what'
2013-11-02 21:28:44.791 Imagepicker[89146:a0b] 21:28:44.791 ERROR: 398: error -66680
2013-11-02 21:28:44.791 Imagepicker[89146:a0b] 21:28:44.791 ERROR: 398: error -66680
2013-11-02 21:28:44.792 Imagepicker[89146:a0b] 21:28:44.792 ERROR: 398: error -66680
2013-11-02 21:28:44.792 Imagepicker[89146:a0b] 21:28:44.792 ERROR: 398: error -66680
我的代码是:
imagePicker = [[UIImagePickerController alloc] init];
imagePicker.mediaTypes =[[NSArray alloc] initWithObjects: (NSString *) kUTTypeMovie,kUTTypeVideo,kUTTypeImage, nil];
[imagePicker setSourceType:UIImagePickerControllerSourceTypePhotoLibrary];
[imagePicker setDelegate:self];
[self presentViewController:imagePicker animated:YES completion:nil];
图像选择器显示,显示取消预览,播放和选择按钮以及显示的对话框操作无法完成。按确定(唯一按钮)后,预览会冻结。
the image picker shows up, shows a preview with cancel, play and choose button and a dialog that says "The operation could not be completed". after pressing "OK" (the only button), the preview freezes.
-(void) imagePickerController:(UIImagePickerController *)picker didFinishPickingMediaWithInfo:(NSDictionary *)info
永远不会被调用。这一切都适用于图像。
never gets called. it all works fine with images.
推荐答案
我对最新的工具链有完全相同的问题,但以下修复了它对我来说;
I've had exactly the same problem with the latest toolchain, but the following fixed it for me;
-
在模拟器硬件菜单上,选择电视输出 - > 640x480。
On the simulator Hardware menu, select TV Out->640x480.
尝试从Xcode启动您的应用程序,它可能会因跳板错误而失败。
Attempt to launch your app from Xcode, it may fail with a springboard error.
在模拟器硬件菜单上,选择电视输出 - >已禁用。
On the simulator Hardware menu, select TV Out->Disabled.
之后,ImagePickerController现在应按预期工作。
After that the ImagePickerController should now work as expected.
这篇关于UIImagePickerController抛出错误:185:创建聚合音频设备时出错:尝试选择视频时“什么”的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!