odd issue with MagickWriteImage (error/exception 435)

The MagickWand interface is a new high-level C API interface to ImageMagick core methods. We discourage the use of the core methods and encourage the use of this API instead. Post MagickWand questions, bug reports, and suggestions to this forum.
Post Reply
mskuma
Posts: 2
Joined: 2011-08-28T04:44:52-07:00
Authentication code: 8675308

odd issue with MagickWriteImage (error/exception 435)

Post by mskuma » 2011-08-28T04:55:06-07:00

Hello

I'm calling MagickWand functions in the DLL (ImageMagick-6.7.2-Q8) from a Basic compiler (Windows OS), and calling MagickWriteImage (my program is threaded). Generally (about 95%+ of the time) the image is written to the disk with no error (I capture the return value of the function & determine any exception/error string). Sometimes I get a fail return value with severity of 435 and exception details of 'unable to open image <filename>: Invalid argument @ error/blob.c/OpenBlob/2588'. However I see the actual image seems to be written ok on the disc. This seems odd to me - can anyone suggest something to me? I notice there seems to be some environment variables relating to max threads or CPU throttling etc - should I try these?

Thanks.

User avatar
magick
Site Admin
Posts: 11077
Joined: 2003-05-31T11:32:55-07:00

Re: odd issue with MagickWriteImage (error/exception 435)

Post by magick » 2011-08-28T05:30:49-07:00

MagickWriteImage() is single threaded and unaffected by max threads and CPU throttling. The exception you received is most likely from the Windows system call _wfopen(). Does it always fail on the same filename? If so, what is it? Does your problem work properly if it is single threaded? What about 2 threads verses 4 threads?

Without additional information it is difficult to determine the source of the problem. Can you post a minimal code set we could use to reproduce the problem?

mskuma
Posts: 2
Joined: 2011-08-28T04:44:52-07:00
Authentication code: 8675308

Re: odd issue with MagickWriteImage (error/exception 435)

Post by mskuma » 2011-08-28T16:07:26-07:00

Thanks for your reply. I'm composing various images prior to saving these, so it doesn't always fail on the same image. I think you're right - I should try adjusting the number of threads or no threads & see if this problem reoccurs.

Post Reply