简体   繁体   English

图像未在ipad模拟器中显示

[英]Images not showing in ipad simulator

I've put items into the folder of this filepath: /Users/ollie/Library/Application Support/iPhone Simulator/6.1/Media/DCIM/100Apple/ because I'm testing a UIImagePickerController and then renamed it to IMG_0002.png as there was already an mp4 file in there though ran the app and opened the view it didn't show and also when I went into the pictures app the mp4 was there though the image wasn't. 我已将项目放入此文件路径的文件夹中: / Users / ollie / Library / Application Support / iPhone Simulator / 6.1 / Media / DCIM / 100Apple /因为我正在测试UIImagePickerController ,然后将其重命名为IMG_0002.png虽然运行应用程序并打开了它没有显示的视图,但是当我进入图片应用程序时,虽然图像不是,但是当我进入图片应用程序时,已经是一个mp4文件了。

I haven't got a clue why this is not working though I suspect it must happen quite a lot. 我不知道为什么这不起作用,虽然我怀疑它必须发生很多。

Thanks in advance. 提前致谢。

For media to show up it needs to be in the index that the device keeps in an internal CoreData DB. 要显示媒体,它需要位于设备保留在内部CoreData DB中的索引中。 Add items to the simulators media by simple dragging the image onto simulator. 通过简单地将图像拖到模拟器上,将项目添加到模拟器媒体中。

Then Mobile Safari opens showing the image. 然后Mobile Safari将打开,显示图像。 From there you can save the photo to the pictures. 从那里你可以将照片保存到图片中。 Then it will show up in the image picker. 然后它将显示在图像选择器中。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM