wand.api — Low-level interfaces

Changed in version 0.1.10: Changed to throw ImportError instead of AttributeError when the shared library fails to load.

class wand.api.c_magick_char_p

This subclass prevents the automatic conversion behavior of ctypes.c_char_p, allowing memory to be properly freed in the destructor. It must only be used for non-const character pointers returned by ImageMagick functions.

wand.api.library = <CDLL '/usr/local/lib/libMagickWand-6.Q16.dylib', handle 7fae22cf99a0 at 109190490>

(ctypes.CDLL) The MagickWand library.

wand.api.libc = <CDLL 'libc.dylib', handle 7fff68f43350 at 109555350>

(ctypes.CDLL) The C standard library.

wand.api.libmagick = <CDLL '/usr/local/lib/libMagickWand-6.Q16.dylib', handle 7fae22cf99a0 at 109190490>

(ctypes.CDLL) The ImageMagick library. It is the same with library on platforms other than Windows.

New in version 0.1.10.

wand.api.load_library()

Loads the MagickWand library.

Returns:the MagickWand library and the ImageMagick library
Return type:ctypes.CDLL