How to call MagickProfileImage

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

How to call MagickProfileImage

Post by bensyverson »

Hi everyone,

I'm using MagickWand in C to do various tasks for a web CMS that I'm building. One of the things I want to do is convert uploaded photos from their native colorspaces to sRGB.

My question is: how exactly do I pass ICC data into MagickProfileImage? The documentation just mentions

Code: Select all

const void *profile
. Should I just read the binary data from the ICC profile into a buffer and pass MagickProfileImage a pointer to the buffer?

Thanks!

- ben
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: How to call MagickProfileImage

Post by anthony »

In 'C' a void pointer is a point to a undescribed block of memory. IM uses that
as a profile could be anything. With that should be some 'length' parameter defining the memory blocks length when the image gets written.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply