load image from file and display 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
prophetic_oleg

load image from file and display image

Post by prophetic_oleg »

Hi. I have installed the ImageMagick-6.3.6-Q16.dll.
And i have create a new project to try using ImageMagick.
Here my code:
#include <Magick++.h>
using namespace Magick;
int main(int argc,char **argv)
{
InitializeMagick(*argv);

Image image("1.jpg");
image.display();
return 0;
}
Program crashed here: Image image("1.jpg");
Why it is happend?

And next problem. I draw my image and want to display it, but in console written this:
unable to open X server : No such file or directory.
How i can display my image?
prophetic_oleg

Re: load image from file and display image

Post by prophetic_oleg »

Please, somebody help me.
Maybe i must make any settings that image is normal open.
Post Reply