[magick-users] Square thumbnails / Filter Sharpen

Anthony Thyssen anthony at griffith.edu.au
Wed Oct 17 17:07:20 PDT 2007


Noel da Costa on  wrote...
| Hi John,
| 
| Thanks for the reply.
| I'm performing a crop, rather than a change of proportion.
| 
| Here's the actual convert command being run:
| 
| convert -geometry 70x70 /assets/thumbnails/20.jpg  -background white - 
| flatten -transparent white -thumbnail x140 -resize '140x<' -resize  
| 50% -gravity center -crop 70x70+0+0 +repage /assets/thumbnails/20.jpg
| 

Do you mean the merging of pixels together to form a more correct
thumbnail?  That is you want the colors left as is.

There is a trade off, between sharpness, and aliasing
(staircase effects on edges, or morie effects in complex patterns)

I would say the simplest way is to either:
  * turn off resize filters completely (using "-filter point" ),
  * Use a very tight filter such "-filter hermite"
  * OR sharpen the effect of the filter "-support 0.5"
    A value less than 1 sharpens, while greater than 1 blurs,

That latter is controlable in the current IM and eariler using
a very badly named option called  -support.   This option really should
have been called  -filter-blur, but that is what it currently called.


---- WARNING WARNING WARNING ----

As part of the development of the General Distortion Operator, -distort
(See IM Examples  http://imagemagick.org/Usage/distorts/#distort )
The resize filters are being redeveloped.
  * Make correct use of the Sinc windowing functions
      Hamming, Hanning, Kaiser (just added)
  * Allow the correct use of windowed Bessel functions for two
    dimensional radial fliters, in distort, and posibly convolution
    kernels.
  * Obsolete the mis-named "-support" as a filter blur setting.
  * Add expert settings to directly specify and:
      filter function, window function, support size, sinc/bessel lobes,
      and of course filter scaling or blur (what was -support)

Basically this is NOT to try an change the default working of resize
(which works extremely well) but to allow better control by people with
expert filter knowledge.

If you don't know anything about filters, I suggest you limit yourself
to just the use of the -filter selection setting.

  Anthony Thyssen ( System Programmer )    <A.Thyssen at griffith.edu.au>
 -----------------------------------------------------------------------------
       How many hardware guys does it take to change a light bulb?
   "Well the diagnostics say it's fine buddy, so it's a software problem."
 -----------------------------------------------------------------------------
     Anthony's Home is his Castle     http://www.cit.gu.edu.au/~anthony/


More information about the Magick-users mailing list