Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
A shell script to add "Kurosawa mode" (as implemented in the videogame Ghost of Tsushima) to your webcam, tested with a Logitech c920 on Ubuntu. Run "bash on" or make it an executable and run `kurosawa on` to activate high-contrast black-and-white; run with "off" to disable/reset.
#!/usr/bin/env bash
if [ $MODE = "on" ]; then
v4l2-ctl -d /dev/video0 --set-ctrl=saturation=0,contrast=190,brightness=105
elif [ $MODE = "off" ]; then
v4l2-ctl -d /dev/video0 --set-ctrl=saturation=128,contrast=128,brightness=120
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.