Skip to content
This repository was archived by the owner on Jul 10, 2024. It is now read-only.

Commit 0f47082

Browse files
authored
Fix missing video recordings for iOS and Android devices (#120)
Add `videoScale` for iOS and `videoSize` for Android to set the video resolution to solve issues recording device screens. This solves issues where no video gets recorded for tests.
1 parent 566c289 commit 0f47082

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/plugin/driver-command-executor.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ async function startScreenRecording(driver: any, sessionId: string) {
55
options: {
66
videoType: "libx264",
77
videoFps: 10,
8+
/* Force iOS video scale to fix '[ffmpeg] [libx264 @ 0x7fda5f005280] width not divisible by 2 (1125x2436)' */
9+
videoScale: "1280:720",
10+
/* Force Android size because some devices cannot record at their native resolution, resulting in error 'Unable to get output buffers (err=-38)' */
11+
videoSize: "1280:720",
812
/* In android, adb can record only 3 mins of video. below timeLimit is used to take longer video */
913
timeLimit: 1800, //in seconds (30 min)
1014
},

0 commit comments

Comments
 (0)