Automated screenrecording xcrun creates video with 2 pixels in addition

169 views Asked by At

To automate screen recording of Xcode UI Tests for app store deployment, I use the command

xcrun simctl io booted recordVideo --codec=h264 --force \(totalUrl.absoluteString.replacingOccurrences(of: "file://", with: "").replacingOccurrences(of: "%20", with: " "))

that is being sent though SBTUITestTunnelHost. So far this works but when I try to upload those screen videos thought AppStore Connect it says for eg the iPhone 6,5´´ screen requires me to upload a video with 886x1920 px but the generated video with xcrun is 888x1920 px. What am I doing wrong with the xcrun command?

enter image description here

1

There are 1 answers

0
EMart On

My goal was to create App Store Connect Screenrecordings for my App.

Unfortunatly i couldn't use xcrun ... recordVideo to record the vidos, due to two reasons:

  1. it exported the videos too large so i had to scale them down in quicktime but they ended up being 888x1920 and
  2. the recording didn't have a sound, so Apple won't accept them in Appstore Connect

So my solution was:

  1. I record a screenvideo with Quicktime and export it as mov file
  2. than scale it up to 886x1920 for 6.5´ screens with https://www.onlineconverter.com/convert
  3. and finally smooth the framerate to a constant 30 fps with HandBrake

C'mon Apple, it can't get any worser, can it?