This project has moved and is read-only. For the latest updates, please go here.

Fred's ImageMagick Scripts

Feb 10, 2015 at 8:25 PM
Just curious if anyone has successfully implemented any of Fred's ImageMagick Scripts

and if so, how did you go about doing this.

There are a lot of cool things there I would like to explore but I have been lost in trying to figure out where to even begin.
Feb 10, 2015 at 9:53 PM
Edited Feb 15, 2015 at 12:07 PM
I have not heard of anyone who translated Fred his script to C#. If I would do this myself I would create a class for each script. But I don't think if you are allowed to do this without his permission due to the license he uses.

His script 2colorthresh would translate to something like this:
public static class TwoColorThresh
  static MagickImage Execute(MagickImage input)
    // This script does the following:
    // convert $input +dither -colors 2 -colorspace gray -contrast-stretch 0 $output

    MagickImage output = input.Clone();
    output.Quantize(new QuantizeSettings()
      Colors = 2, // -colors 2
      DitherMethod = DitherMethod.No, // +dither,
      ColorSpace = ColorSpace.GRAY // -colorspace gray
    // The overload below won't work until the next release.
    output.ContrastStretch(0); // -contrast-stretch 0

    return output;
Feb 10, 2015 at 10:21 PM
Interesting. That seems simple enough.

There are a few scripts that we could definitely use but I might be better off trying to write my own following your example. MagickNet seems more then comprehensive enough but I just need to get more familiar with it and ImageMagick in general.
Feb 13, 2015 at 9:14 AM
I have asked Fred for a collaboration and he granted me permission to start a .NET project that will be licensed under the same conditions as his scripts. It might take a while before I will start with this but you can find the project here:
Feb 14, 2015 at 4:47 PM
That will be fantastic. Looking forward to following it along.
Apr 25, 2015 at 11:21 PM
Edited Apr 25, 2015 at 11:21 PM
The first two scripts have been published on NuGet. You can keep track of the list here: