How to add video to iphone simulator

前端 未结 8 1435
情书的邮戳
情书的邮戳 2020-12-28 15:43

Can anyone tell me how to add video the iPhone simulator so that I can test some apps I am working on? Thanks in advance!

相关标签:
8条回答
  • 2020-12-28 16:21

    Short answer:

    1. Drop your video file into ~/Library/Application Support/iPhone Simulator/6.1/Media/DCIM/100APPLE/ and maybe delete the PhotoData file in Media.

    Long Answer:

    1. Make sure your movie file type is supported on the iPhone. I used a .mov
    2. Open the Library. (YourUserName/Library) If you can't find the file, it is hidden. Make it visible or user Terminal.
    3. Navigate to ~/Library/Application Support/iPhone Simulator/ If you have multiple iOS Simulators pick the one your are developing for currently. (I had 5.0, 5.1, 6.0 and 6.1)
    4. Navigate to ~/Library/Application Support/iPhone Simulator/6.1/Media/DCIM/100APPLE/ and drop in your video file. If the 100APPLE directory doesn't exist, create it.
    5. Sometimes you have to delete the PhotoData file in Navigate to ~/Library/Application Support/iPhone Simulator/6.1/Media/ to force the Simulator to recognize the new file since you didn't add it through normal means.

    Xcode 4.6.3 and MacOS 10.8.4 fyi. Haven't tried on Xcode 5.

    0 讨论(0)
  • 2020-12-28 16:22

    I did the same as you do with images, drag dropped the video onto the iOS simulator not just photo's app but any app can be running on it at the time you drag drop.

    Step 1: Drag drop.

    enter image description here

    Step 2: iOS simulator opens up safari to play the video file.

    enter image description here

    Step 3: Click on the share icon to get the Save Video option in the action's list.

    enter image description here

    But clicking on Save Video action for so many times nothing happens and nothing gets added to the albums. Any ideas? Even tried copy pasting the video file to the simulator's DCIM path.

    0 讨论(0)
提交回复
热议问题