summaryrefslogtreecommitdiff
path: root/guides/imagemagick.org
diff options
context:
space:
mode:
Diffstat (limited to 'guides/imagemagick.org')
-rw-r--r--guides/imagemagick.org15
1 files changed, 15 insertions, 0 deletions
diff --git a/guides/imagemagick.org b/guides/imagemagick.org
new file mode 100644
index 0000000..25859e8
--- /dev/null
+++ b/guides/imagemagick.org
@@ -0,0 +1,15 @@
+ImageMagick recipes I should stuff into config files or scripts, but
+haven't yet.
+* Configuration
+** Allow conversion from/to PDF
+- Open ImageMagick's =policy.xml= configuration file.
+- Locate the =<policy>= tag with a =pattern= including "PDF".
+- Comment it out.
+* Comparing images
+~magick compare~ is a thing; ~magick convert~ can also do [[https://stackoverflow.com/a/33673440][neat stuff]]:
+#+begin_src sh
+convert '(' a.png -flatten -grayscale Rec709Luminance ')' \
+ '(' b.png -flatten -grayscale Rec709Luminance ')' \
+ '(' -clone 0-1 -compose darken -composite ')' \
+ -channel RGB -combine diff.png
+#+end_src