Several Questions regarding Magick++

Magick++ is an object-oriented C++ interface to ImageMagick. Use this forum to discuss, make suggestions about, or report bugs concerning Magick++.
Post Reply
alanchcw
Posts: 7
Joined: 2019-09-29T02:11:05-07:00
Authentication code: 1152

Several Questions regarding Magick++

Post by alanchcw » 2019-09-29T02:34:29-07:00

Hi,

I am new to ImageMagick. I download the ImageMagick sources and built them in VS2015 successfully.

Now I try to understand Magick++. I read the online documents back and force, including:

1. https://imagemagick.org/script/magick++.php
2. https://imagemagick.org/Magick++/Install.html

But still have many questions:

1. Does Magick++ provide a seperate DLL or static library + header file for application to invoke? Based on some documents, it seems Magick++ just provide header file and the actual DLL is just from ImageMagick. I see there is a ImageMagickObject.dll file after built. Is that file the actual DLL invoked?

2. How to redistribute application developed with Magick++? I read documents and it said Imagick need to be installed for Magick++ to work, but that is too inconvneient. It is better to only redistribute one or two DLLs, such as ImageMagickObject.dll with my application.

3. I read https://imagemagick.org/Magick++/Install.html for 5 times. But still cannot understand how to install Magick++ in Windows/Visual C++. Under "Windows '9X, NT, 2003, 2008, XP, & Windows 7", it said there is a "win2k" directory. But I check "win2k" and only find "IMDisplay" folder, I try to go into the folder and find a IMDisplay.dsp file, I try to open that file in VS6, but get an error "The makefile is not generated by Visual Studioxxx"

4. Also in the above installation guide, it said "Please read the configuration and build instructions in README.txt (under the heading "Windows Win2K/XP VISUAL C++ 8.0 COMPILATION") in order to build Magick++.". I try to find the "README.txt" under "ImageMagick" and "ImageMagick\Magick++" subfolders, then search for the heading but can find it neither files. So I don't know how to install Magick++ and what the installation of Magick++ will do?

Thanks

snibgo
Posts: 12299
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Several Questions regarding Magick++

Post by snibgo » 2019-09-29T05:03:33-07:00

Three APIs to ImageMagick are:

1. C access to MagickCore.

2. C access to MagickWand.

3. C++ access. This is often called "Magick++". So you can write CPP programs that use ImageMagick libraries to process images.

I build ImageMagick on Windows 8.1 using GNU C++ build tools, from the Cygwin package. This makes DLL files:

Code: Select all

24/09/2019  17:34         5,358,394 cygMagick++-7.Q32HDRI-4.dll
24/09/2019  17:34        10,762,765 cygMagickCore-7.Q32HDRI-6.dll
24/09/2019  17:34         4,050,653 cygMagickWand-7.Q32HDRI-6.dll
When I build a C++ program, I copy the EXE to the same directory as those DLL files, and it works. So perhaps copying the DLLs and EXE to another machine would also work. I haven't tried that.
alanchcw wrote:I read documents and it said Imagick need to be installed for Magick++ to work, ...
That is not correct. IMagick is a different product that provides a PHP interface to ImageMagick. So IMagick needs ImageMagick, but ImageMagick does not need IMagick.

Sorry, I know nothing about distributing Magick++ binary programs. Obviously ImageMagick must be installed on the target machine. If the same versions of ImageMagick are on source and target machines, I expect you can simply copy the binary file. But I don't know.
snibgo's IM pages: im.snibgo.com

alanchcw
Posts: 7
Joined: 2019-09-29T02:11:05-07:00
Authentication code: 1152

Re: Several Questions regarding Magick++

Post by alanchcw » 2019-09-29T16:23:44-07:00

I check the VisualMagick\lib subfolder and also find some files related to Magick++:

Sorry but the image cannot show, so I have to paste the URL:

https://www.dropbox.com/s/w5wd61fp96nmn ... Magick.jpg

But these files contain a DB prefix, seems to be related to database?

snibgo
Posts: 12299
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Several Questions regarding Magick++

Post by snibgo » 2019-09-29T16:34:49-07:00

Are those DLL files? I don't use Visual Studio. Is your "debug" setting on? If so, I suspect "_DB" stands for "debug". The pre-built ImageMagick binaries have "_RL" DLLs, for "release", I think.
snibgo's IM pages: im.snibgo.com

alanchcw
Posts: 7
Joined: 2019-09-29T02:11:05-07:00
Authentication code: 1152

Re: Several Questions regarding Magick++

Post by alanchcw » 2019-09-30T16:32:10-07:00

These are all .lib files. And from the sizes of these files(several MB), I think they are not import library for DLLs, but static libraries.

I check the projects. Yes, they are using "Debug" settings. So I think what you guess is correct. DB means "Debug", not "Database.

Jullez
Posts: 1
Joined: 2019-11-08T20:14:03-07:00
Authentication code: 1152

Re: Several Questions regarding Magick++

Post by Jullez » 2019-11-10T21:06:08-07:00

snibgo wrote:
2019-09-29T05:03:33-07:00
So IMagick needs ImageMagick, but ImageMagick does not need IMagick.
IMagick is the extension to ImageMagick, do I get it right, And it can be uninstalled at any moment without consequences?

snibgo
Posts: 12299
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Several Questions regarding Magick++

Post by snibgo » 2019-11-10T21:17:15-07:00

IMagick is not an extension to ImageMagick.

If you uninstall IMagck, a consequence is that you won't be able to use it, obviously.
snibgo's IM pages: im.snibgo.com

Post Reply