Code: Select all
convert file.tif -channel H -fx "hue < 0.917 && hue > 0.083 && saturation > 0.10 ? r * 0.97 : r" +channel file-fx.tif
1. -fx takes terribly long time to work, on big files it really adds up
2. It creates sharp border. 0.97 translates to ca. 7-8 levels on 8 bit images (BTW - how IM rounds up levels in this case - any way to know it?)
Solution to second problem could be creation of mask, feather it a bit, lower reds in underlaying layer and at last apply mask. But: Is it possible to create mask without -fx in this case? If -fx is still necessary it will only increase length of processing.
My version of IM:
Code: Select all
Version: ImageMagick 6.9.3-5 Q8 x64 2016-02-20 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2015 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Visual C++: 180040629
Features: Cipher DPC Modules OpenMP
Delegates (built-in): bzlib cairo freetype jng jp2 jpeg lcms lqr openexr pangocairo png ps rsvg tiff webp xml zlib