Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to add HEIC image to iOS simulator?

I'm trying to pass an HEIC image file to the iOS simulator, I'm trying to do it because I need to verify why my app isn't working with HEIC images, but I only have an IPhone 6 (IPhone 7 or newer is required, that's why I need to use the iOS Simulator).

I used this command: xcrun simctl addmedia booted ./IMG_0237.HEIC and it failed with the error shown in the image below, but worked with a JPG image.

Is there a way to put HEIC images on ios Simulator?

commands executed

like image 803
Pedro Hidalgo Avatar asked Dec 06 '25 18:12

Pedro Hidalgo


1 Answers

Update: Adding HEIC images either by drag&drop or xcrun simctl addmedia finally works with Xcode 9.3 beta and the iPhone X 11.3 simulator.

You can put a HEIC file on iCloud, login on the simulator, and access it from there. There doesn't appear to be a way to get it into the gallery (Photo app) though. That is: I did manage to increment the counter in the Photo app and have a grey rectangle appear as additional photo. But at least the iPhone X 11.2 simulator doesn't seem to be capable of displaying HEIC images. It seems like the simulator is useless to test actual device behaviour.

like image 135
vbraun Avatar answered Dec 08 '25 08:12

vbraun



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!