Here's the command I want to duplicate in with MagickWand:
Code: Select all
convert holocaust_sm.jpg \
-edge 1 -negate -normalize \
-colorspace Gray -blur 0x.5 -contrast-stretch 0x50% \
color-in.gif
# For heavily shaded pictures...
# #-segment 1x1 +dither -colors 2 -edge 1 -negate -normalize \
Code: Select all
-contrast-stretch 0x50%
The code I've been working with has variables attached to sliders, so that i can change their value on the fly and regenerate the image. Heres the code:
Code: Select all
status = MagickReadImageBlob(magick_wand, [dataObject bytes], [dataObject length]);
status = MagickEdgeImage(magick_wand, edgeRadius);
status = MagickNegateImage(magick_wand, MagickTrue);
status = MagickNormalizeImage(magick_wand);
status = MagickSetImageType(magick_wand, 2);//gray colorspace
status = MagickBlurImage(magick_wand,blurRadius, blurSigma);
size_t my_size;
unsigned char * my_image = MagickGetImageBlob(magick_wand, &my_size);....