Skip to content

fjcaetano/ios-simulator-gif

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

35 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

📱 ios-simulator-gif homebrew PRs welcome

Record a gif from your iOS simulator in a jiffy

Example GIF

Installation

Assuming that you have Homebrew installed, execute the following steps:

  1. Use this repository as a "tap" (alternative package repository):
$ brew tap fjcaetano/ios-simulator-gif https://github.com/fjcaetano/ios-simulator-gif.git
  1. Install ios-simulator-gif (and dependencies):
$ brew install ios-simulator-gif

Usage

$ ios-simulator-gif [options] {out_file} {-- [ffmpeg options]}
Options Description Default value
-r, --rate Framerate of the output 15
-f, --format Output format gif
-vf, --video-filter Video filter for ffmpeg scale=320:-1
-t, --transpose Transpose the video for landscape orientation N/A
--no-watermark Remove watermark from gif N/A
-h, --help Prints helper message N/A
-v, --version Prints current version N/A

If no file name is given, it will save the gif to ./simulator.gif

When recording a video in landscape mode you'll need to provide the appropriate transposing argument. It's usually the following:

  1. --transpose 1 when the simulator is rotated 90º (camera to the right)
  2. --transpose 2 when the simulator is rotated 270º (camera to the left)

Sending extra arguments to ffmpeg

If you need to send extra arguments to ffmpeg, everything sent after double slashes (--) will be sent to ffmpeg as arguments:

$ ios-simulator-gif -r 30 example.gif -- -b 128k