Re: Compare (subimage-search) rotated image without intermediary files
Posted: 2017-05-21T13:15:03-07:00
You need 7.0.5.7. Likely it would do the job faster, but probably not by much.
I ran the following 3 times:
real 0m2.756s
real 0m2.731s
real 0m2.753s
real 0m3.009s
real 0m3.020s
real 0m3.026s
So the first command is about 9% faster.
I ran the following 3 times:
Code: Select all
time magick compare -metric rmse -subimage-search -dissimilarity-threshold 1 \
\( 370669patch.png +repage -background black -alpha background \) \
\( 224977object4.png +repage -background black -alpha background +distort SRT 180 -trim +repage \) \
-alpha off null:
real 0m2.731s
real 0m2.753s
Code: Select all
magick \
\( 370669patch.png +repage -background black -alpha background \) \
\( 224977object4.png +repage -background black -alpha background \
-background none -virtual-pixel background -distort SRT 180 -trim +repage \) miff:- |\
magick compare -metric rmse -subimage-search -dissimilarity-threshold 1 - null:
real 0m3.020s
real 0m3.026s
So the first command is about 9% faster.