Freeing an pixel packet or image

Magick++ is an object-oriented C++ interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick++.
Post Reply
Posts: 31
Joined: 2007-11-23T15:34:51-07:00

Freeing an pixel packet or image

Post by Bob-O-Rama » 2011-11-13T10:46:18-07:00


I fear this is going to be the "stupidest question ever" but here it goes...

I have a process where I load up a bunch of images, processes them. Along the way I'd like to throw away some of them to save on the RAM requirement. Is there a way to free an image objects memory / discard the image / ...


-- Bob

User avatar
Site Admin
Posts: 10807
Joined: 2003-05-31T11:32:55-07:00

Re: Freeing an pixel packet or image

Post by magick » 2011-11-13T16:26:33-07:00

Image resources are destroyed when an object goes out of scope. Otherwise call delete (e.g. delete _image).

Post Reply