about summary refs log tree commit diff
path: root/edit.mk
diff options
context:
space:
mode:
Diffstat (limited to 'edit.mk')
-rw-r--r--edit.mk13
1 files changed, 12 insertions, 1 deletions
diff --git a/edit.mk b/edit.mk
index 48f6856..a9fa934 100644
--- a/edit.mk
+++ b/edit.mk
@@ -12,6 +12,10 @@ change:
 
 .PHONY: commit edit change
 
+IN ?=
+OUT ?=
+SCALE ?= x400
+
 compress:
     # => https://kokorobot.ca/site/image_optimization.html
 	magick $(IN) \
@@ -19,13 +23,20 @@ compress:
         -strip \
         -quality 85 \
         -interlace line \
+        -scale $(SCALE) \
         $(OUT)
         # -colorspace sRGB \
 
 dither:
     # => https://legacy.imagemagick.org/Usage/quantize/#ordered-dither
 	magick $(IN) \
-        -ordered-dither o8x8 \
+        -sampling-factor 4:2:0 \
+        -strip \
+        -quality 85 \
+        -interlace line \
+        -ordered-dither o3x3 \
+        -scale $(SCALE) \
         $(OUT)
+        # -colorspace Gray \
 
 .PHONY: compress dither