Custom colors when simulating device appearance

I'm not a fan of the colors used by the simulator when "Simulate Device Appearance" is enabled, and I always change them to my preferred color scheme before I share any screen shots.

This is trivial for a PNG, but less so with an animated GIF recorded at 50 FPS. Aseprite can do this, but I've yet to get it to export the updated GIF without munging the playback rate, so I end up using an online filter that sort-of comes close to what I want. Even if it did work properly, its still an additional step that I'd rather not have to take.

Ideally I'd be able to define a hex value to use for black and white (perhaps in the preference pane), and the simulator would honor that setting when recording or taking a screen shot.

This would eliminate additional process for screenshots for myself and other developers who share my sentiment about the sepia tones that are currently in place.

7 Likes

I agree this would be very handy in the Simulator.

Meanwhile I have a right click script (one line command) that does it using Image Magick command line tool. Happy to share if it's of use

Another work around: It's a little fiddly to setup the first time, but the gifsicle command line app supports color mapping and is dedicated to fidling with GIFs so it seems to keep things working in the minimal testing I did. Minimal write up here:

https://til.cafe/blog/2023/convert-gifs-to-black-and-white-using-gifsicle/

... But to keep repeat the key bits here for future reference... you need a gifsicle color map:
Contents of pd_colors.txt:

50 47 40
177 174 167

And then pass that into the --color-map flag:

gifsicle --gamma=1 --use-colormap=pd_colors.txt <rain_bw.gif > rain_pd.gif

I just had to do this again.

So, here is my command

file="image.gif"
/opt/homebrew/bin/magick "$file" -fuzz 0% -fill 'rgb(177,174,167)' -opaque 'rgb(255,255,255)' -fill 'rgb(50,47,40)' -opaque 'rgb(0,0,0)' "$file"

Works for both PNG and GIF anim.

I have it set up on ContextMenu macOS app, so I can right click any PNG/GIF and do it on a single click.

1 Like