Best way to generate multiple thumbnails from one image

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
bensyverson

Best way to generate multiple thumbnails from one image

Post by bensyverson »

Hi everyone,

Another question about MagickWand in C... I want to read in an image, and generate a few different sized images from it. What's the best way to go about doing this? Right now, I'm reading an image into a MagickWand, and then cloning the whole wand structure a few times:

MagickWand *original, *large, *medium, *small;
large = CloneMagickWand(original);
medium = CloneMagickWand(original);
small = CloneMagickWand(original);

This seems like a strange way to do it, since you can have multiple images per wand. Is there some way to duplicate a certain image in a wand without duplicating the whole wand?

Thanks!
bensyverson

Re: Best way to generate multiple thumbnails from one image

Post by bensyverson »

Nevermind, I've switched to MagickCore...
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: Best way to generate multiple thumbnails from one image

Post by anthony »

Magick core clones the images anyway, as part of the operation.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply