#!/bin/bash SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd ) WORKING=$PWD head -n 13 "$SCRIPT_DIR/overlaytexttemplate.html" >"$SCRIPT_DIR/overlaytext.html" echo $@ >>"$SCRIPT_DIR/overlaytext.html" tail -n 5 "$SCRIPT_DIR/overlaytexttemplate.html" >>"$SCRIPT_DIR/overlaytext.html" firefox -P screenshitter --headless --window-size 3840,2160 --screenshot "$WORKING/ots1.png" "file:///$SCRIPT_DIR/overlaytext.html" convert "$WORKING/ots1.png" -fuzz 12% -transparent "#00ff00" "$WORKING/ots2.png" #convert ns2.png -trim "n$i.png" # blender wants to scale to fit, # and if you want a 1:1 scale image i don't know what the *fuck* it's doing with an origin point. convert "$WORKING/ots2.png" "$WORKING/overlaytext.png" rm "$WORKING/ots1.png" "$WORKING/ots2.png" "$SCRIPT_DIR/overlaytext.html"