blob: 08c61cd52c1bc67f06f99cf251c3e5c5bcbc0847 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
#!/bin/sh
# I have two cameras on my laptop and the first one is an IR camera (video0)
# If the hostname matches that of my laptop, use the second camera
camera="/dev/video0"
if [ -n "$1" ]; then
camera="$1"
elif [ $HOSTNAME = "thinkslav" ]; then
camera="/dev/video2"
fi
pkill -f "$camera" || mpv \
--gpu-context=wayland \
--profile=low-latency \
--no-osc \
--no-input-default-bindings \
--input-conf=/dev/null \
--geometry=-0-0 \
--autofit=25% \
--title="mpvfloat" "av://v4l2:$camera"
|