optionally use GraphicsMagick

This commit is contained in:
John Cupitt 2008-02-21 16:10:24 +00:00
parent a6b0d8471b
commit a4db478be3
4 changed files with 19 additions and 7 deletions

View File

@ -7,6 +7,7 @@
- you can now set the jpeg quality factor for tiff pyramids (thanks Joe)
- you can now shrink jpegs during read, see "man im_jpeg2vips"
- added CMYK JPEG write
- optionally use GraphicsMagick (thanks Bob Friesenhahn)
12/12/07 started 7.13.3
- added "include <cstring>" to VImage.cc to help gcc 4.3

5
TODO
View File

@ -61,11 +61,6 @@ WONTFIX
or something like that?
- can we use GraphicsMagick instead of ImageMagick?
no: current stable GraphicsMagick is missing (at least) QuantumRange and
GetNextImageAttribute() ... perhaps this will be fixed in 1.2
- TIFF load/save should use meta system for unknown tags
- balance should use new meta stuff

View File

@ -180,12 +180,18 @@ if test x"$with_fftw3" != "xno"; then
fi
# ImageMagick ... detect attribute iteration too
# Optionally look for GraphicsMagick instead
AC_ARG_WITH([magick], AS_HELP_STRING([--without-magick], [build without libMagic (default: test)]))
AC_ARG_WITH([magickpackage], AS_HELP_STRING([--with-magickpackage], [magickpackage to use (default: ImageMagick)]))
if test x"$with_magickpackage" == "xno"; then
with_magickpackage=ImageMagick
fi
if test x"$with_magick" != "xno"; then
PKG_CHECK_MODULES(MAGICK, ImageMagick,
PKG_CHECK_MODULES(MAGICK, $with_magickpackage,
[AC_DEFINE(HAVE_MAGICK,1,[define if you have libMagick installed.])
PACKAGES_USED="$PACKAGES_USED ImageMagick"],
PACKAGES_USED="$PACKAGES_USED $with_magickpackage"],
[AC_MSG_WARN([libMagick not found; disabling Magick support])])
fi

View File

@ -16,6 +16,8 @@
* - set RGB16/GREY16 if appropriate
* 10/8/07
* - support 32/64 bit imagemagick too
* 21/2/08 Bob Friesenhahn
* - use MaxRGB if QuantumRange is missing
*/
/*
@ -85,6 +87,12 @@ im_magick2vips_header( const char *filename, IMAGE *im )
#include <magick/api.h>
/* pre-float Magick used to call this MaxRGB.
*/
#if !defined(QuantumRange)
# define QuantumRange MaxRGB
#endif
#ifdef WITH_DMALLOC
#include <dmalloc.h>
#endif /*WITH_DMALLOC*/
@ -211,7 +219,9 @@ parse_header( Read *read )
IMAGE *im = read->im;
Image *image = read->image;
#ifdef HAVE_GETNEXTIMAGEATTRIBUTE
const ImageAttribute *attr;
#endif /*HAVE_GETNEXTIMAGEATTRIBUTE*/
Image *p;
int i;