snippets

webcam camera. webcamera lol

this one is basically a one-liner for taking two quick pics with your webcam. it uses ffmpeg, obviously.

change $PICPATH to wherever you want to store these pictures. you might have to tweak the input device for ffmpeg, too. and if you don’t want any terminal logging, you can take out all references to gum.

code copied!
	#!/bin/bash

PICPATH="/home/kat/Pictures/Camera/webcam"

echo "taking pictures!" | gum style --foreground "#f4b8e4" --border none

ffmpeg -f video4linux2 -i /dev/video0 -vframes 2 -video_size 1920x1080 "$PICPATH/webcam_pic_$(date '+%a__%b%d__%H_%M_%S')%3d.jpeg" -hide_banner -loglevel error

echo "done!" | gum style --foreground "#f4b8e4" --border none