Making it easier to use ImageMagick libraries on Windows

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.

Making it easier to use ImageMagick libraries on Windows

Postby DanKegel » 2013-06-06T13:10:53+00:00

In viewtopic.php?f=1&t=8577
a user talked about confusion when trying to use the ImageMagick API
in Visual C++.
The standard answer he was given was "Just copy the project files from the demo directory",
but IMHO ImageMagick could do better than that.

Boost, for instance, provides very clear instructions
http://www.boost.org/doc/libs/1_46_0/mo ... st-library

Part of what makes life easier for casual Boost users is that their headers include pragmas like this:

#ifndef IMAGEMAGICK_NOAUTOLINK
#if DEBUG
#pragma comment(lib, "Core_DB_magick_.lib"
#else
#pragma comment(lib, "Core_RL_magick_.lib"
#endif
#endif

so users don't have to know or care what the individual libraries are named;
they only need to tell Visual C++ what directory they're in.

Would there be any interest in a patch adding this feature?
DanKegel
 
Posts: 11
Joined: 2013-06-06T11:04:20+00:00

Re: Making it easier to use ImageMagick libraries on Windows

Postby magick » 2013-06-06T15:39:33+00:00

Post a URL to the patch. We'll test it and if it works, we'll include it in the next point release of ImageMagick. Thanks.
User avatar
magick
Site Admin
 
Posts: 9630
Joined: 2003-05-31T11:32:55+00:00

Re: Making it easier to use ImageMagick libraries on Windows

Postby dlemstra » 2013-07-08T13:51:17+00:00

Did you receive a patch for this?
.NET + ImageMagick = Magick.NET https://magick.codeplex.com, @MagickNET, Donate
User avatar
dlemstra
 
Posts: 432
Joined: 2013-05-04T15:28:54+00:00

Re: Making it easier to use ImageMagick libraries on Windows

Postby magick » 2013-07-09T03:29:42+00:00

Not that we can recall.
User avatar
magick
Site Admin
 
Posts: 9630
Joined: 2003-05-31T11:32:55+00:00

Re: Making it easier to use ImageMagick libraries on Windows

Postby dlemstra » 2013-07-09T04:20:20+00:00

I will submit one later this week.

EDIT:

Patches have been applied. You should define STATIC_MAGICK to enable this:
Code: Select all
#define STATIC_MAGICK
#include "Magick++.h"


When you are using STATIC_MAGICK and don't want auto linking magick you should define NOAUTOLINK_MAGICK

Code: Select all
#define STATIC_MAGICK
#define NOAUTOLINK_MAGICK
#include "Magick++.h"
.NET + ImageMagick = Magick.NET https://magick.codeplex.com, @MagickNET, Donate
User avatar
dlemstra
 
Posts: 432
Joined: 2013-05-04T15:28:54+00:00


Return to Developers

Who is online

Users browsing this forum: No registered users and 5 guests