Skip to content

Instantly share code, notes, and snippets.

@katoy

katoy/icons.png

Last active Dec 10, 2015
Embed
What would you like to do?
Sample for ImageMagick.
/bin/sh
# convert --version
# Version: ImageMagick 6.8.0-7 2012-12-05 Q16 http://www.imagemagick.org
# See http://www.imagemagick.org/Usage/compare/
\rm -f test_*.gif
\rm -f *.jpg
compare bag_frame1.gif bag_frame2.gif test_compare.gif
compare bag_frame1.gif bag_frame2.gif \
-compose Src test_compare_src.gif
compare bag_frame1.gif bag_frame2.gif \
-compose Src -highlight-color White -lowlight-color Black test_compare_src_color.gif
composite bag_frame1.gif bag_frame2.gif \
-compose difference test_difference_composite.gif
convert bag_frame1.gif bag_frame2.gif \
-compose difference -composite -colorspace Gray test_difference_convert_gray.gif
convert bag_frame1.gif bag_frame2.gif \
-compose difference -composite -separate -evaluate-sequence add test_difference_convert_add.gif
# -----------------
convert bag_frame1.gif bag_frame1.jpg
composite bag_frame1.gif bag_frame1.jpg \
-compose difference test_difference_jpeg.gif
convert test_difference_jpeg.gif \
-auto-level test_difference_convert_autolevel.gif
# -----------------
convert -delay 50 bag_frame1.gif bag_frame2.gif -loop 0 test_flicker_cmp.gif
# -----------------
@katoy

This comment has been minimized.

Copy link
Owner Author

@katoy katoy commented Dec 22, 2012

ImageMagick をつかって画像の差分を得る方法の比較。

See http://www.imagemagick.org/Usage/compare/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment