Lazarus

Programming => Graphics and Multimedia => Graphics => Topic started by: Segator on November 29, 2018, 04:27:15 pm

Title: [Solved] Vampyre Imaging Library "Blending destination canvas error"
Post by: Segator on November 29, 2018, 04:27:15 pm
Hi Lazarus users, first of all thanks to the creator for the great job of Vampyre Imaging Libray.

As the subject say (and i site the 922 line of ImagingCanvases.pas for the raised error create), my problem is with this type of image, specific MNG or APNG (Animated PNG), take the demo LCL Imager include as example project (my project is other but i think if we can fix here, i can fix in my own), so when you try to load specific type of PNG animated this exception show and no image is show, i attach 2 imagen example below.

Test the issue with Lazarus 1.8.4, Lazarus trunk 2.1.0, Linux, Windows, 32 and 64bits.
Title: Re: Vampyre Imaging Library "Blending destination canvas cannot be in indexed mode"
Post by: wp on November 29, 2018, 05:59:18 pm
I tested your two images in the LCLImager of VampyreImaging and found the crash too. But since the same crash happens with the Delphi version (demo VCLImageBrowser) I am rather sure that this is related to some limitation in Vampyre. i saw that you already reported the error in the author's forum - yes, that's the way to go.

I am attaching a working demo of the FreeImage library. It loads the two images without any problems. (I did not include the freeimage.dll which you must download from their site).

And even the LCL itself is able to load the images correctly: Just add a TImage to a form and load the images via the propery Picture.
Title: Re: Vampyre Imaging Library "Blending destination canvas cannot be in indexed mode"
Post by: Segator on November 29, 2018, 07:20:21 pm
I tested your two images in the LCLImager of VampyreImaging and found the crash too. But since the same crash happens with the Delphi version (demo VCLImageBrowser) I am rather sure that this is related to some limitation in Vampyre. i saw that you already reported the error in the author's forum - yes, that's the way to go.

I am attaching a working demo of the FreeImage library. It loads the two images without any problems. (I did not include the freeimage.dll which you must download from their site).

And even the LCL itself is able to load the images correctly: Just add a TImage to a form and load the images via the propery Picture.

Yes but i want the animation-convertion-manipulation that Vampyre Imaging Library support, the LCL itself not supported, i keep the FreeImage in "totest list" but i prefer not dll dependency
Title: Re: Vampyre Imaging Library "Blending destination canvas cannot be in indexed mode"
Post by: wp on November 29, 2018, 07:37:42 pm
Then I wish you good luck with your post in the Vampyre forum.
Title: Re: Vampyre Imaging Library "Blending destination canvas cannot be in indexed mode"
Post by: Segator on December 01, 2018, 04:50:58 pm
Thanks to the responce, the developer of this library fix the issue.
Title: Re: [Solved] Vampyre Imaging Library "Blending destination canvas error"
Post by: wp on December 01, 2018, 07:12:30 pm
Good!