I first use Image Magick to auto-rotate my scanned images, then I realized that I can do much more whit it. I was trying to process Landsat Satellite images and it worked.
Basic Landsat 8 Pansharpening workflow:
- combine three Landsat bands (usually 2,3,4) to RGB image
- change the Color Space to LAB(or a similar one, with one channel representing light(gray) values)
- scale image to 200%
- separate channels
- replace the Lightness channel with the Landsat Panchromatic Band (in Landsat 8 it’s Band 8)
- recombine channels to previous Color Space
- change the Color Space back to RGB
Consequence: The final product resolution is 15m, the original was 30m.
Due to the different sensor and/or spectral characteristic of the bands (the panchromatic band tend to be a bit darker) it is suggested to do a histogram match between Lightness channel and Band 8 in step 5.
In Landsat 7 the difference was so big that it was nearly impossible to reproduce the original RGB image. In Landsat 8 the difference is much smaller so a simple histogram match can reproduce the original image with just a little shift in the overall colors.
(no more need to hire a magician to do some “Magick”)
I found a script already doing this in the Image Magick shell version:
I would be great if this function is implemented in Magick.NET but I don’t know how useful it would be in general image processing tasks.