Page 1 of 1

NoDecodeDelegateForThisImageFormat

Posted: 2007-10-23T09:45:32-07:00
by prophetic_oleg
here my code:

#include <Magick++.h>
#include <string>
#include <iostream>
using namespace std;
using namespace Magick;
int main( int /*argc*/, char ** argv)
{

// Initialize ImageMagick install location for Windows
InitializeMagick(*argv);

try {
Image image("granite.png");
}
catch( exception &error_ )
{
cout << "Caught exception: " << error_.what() << endl;
return 1;
}

return 0;
}

And i have this eeror:
Caught exception: button.exe: NoDecodeDelegateForThisImageFormat

Why it is happening?
Please, help me.

Re: NoDecodeDelegateForThisImageFormat

Posted: 2007-10-23T10:53:34-07:00
by magick
Type
  • convert granite.png granite.miff
Do you get the same exception? If so you most likely are using a version of ImageMagick that did not include PNG support at build time. To confirm type
  • identify -list format
    identify -list configure
Was PNG listed as a supported format?

Re: NoDecodeDelegateForThisImageFormat

Posted: 2007-10-24T00:07:15-07:00
by prophetic_oleg
after
convert granite.png granite.miff
i am not ger any error and file granite.miff was created.

and in identify -list format

The PNG was listed as a supported format.

Re: NoDecodeDelegateForThisImageFormat

Posted: 2007-10-24T01:46:37-07:00
by prophetic_oleg
magick thank you.
All is work.
But i have other question:
when i wright:
image.display();
i have this error: UnableToOpenXServer 'No such file or directory'
As to me to get rid of it?

Re: NoDecodeDelegateForThisImageFormat

Posted: 2007-10-30T19:20:27-07:00
by anthony
You need a DISPLAY environment variable pointing to a running X windows display.