Welcome
Guest
Sign up
Sign in
Products
.NET Components
Java Components
SSRS Rendering Extensions
JasperReports Exporters
SharePoint Components
Product Family Packs
Free Utilities & Components
Services
Aspose Consulting
Support Services
Purchase
Buy Online
Free Trials
Purchase Policies
Renewal Policies
Reselling Policies
Find a Reseller
Purchase FAQ
EULA
Sales Support
Support
Docs
Examples
Forums
Blogs
Downloads
Videos
Corporate
About Us
Contact Us
Community
Customers
Press Center
Careers
Privacy Policy
Terms of Use
Aspose.com
»
Public Forums for Customers an...
»
Aspose.Metafiles Product Famil...
»
Re: NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
Last post 02-05-2009, 12:03 PM by
BrentP
. 3 replies.
Sort Posts:
Oldest to newest
Newest to oldest
Previous
Next
02-03-2009, 4:43 PM
163253
BrentP
Joined on 02-03-2009
Posts 3
NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
Attachment:
Present (inaccessible)
Subscribe
Hi,
I have been utilizing a free API for transforming WMF files into PNG files and which is very buggy, so I thought I'd download Aspose Metafile 1.3.3.0 to see how it compares. On the whole, I've had really good success rendering files that the other API can't handle, but there are a couple of WMFs that end up throwing the following exception:
Exception in thread "main" java.lang.NegativeArraySizeException
at java.awt.image.DataBufferByte.<init>(DataBufferByte.java:42)
at java.awt.image.Raster.createInterleavedRaster(Raster.java:253)
at java.awt.image.BufferedImage.<init>(BufferedImage.java:367)
For these cases, the height or width attributes on the WmfMetalfile return a negative value and apparently chokes later on trying to create an array with a negative size. I can view the WMF fine in Windows and can translate it to a PNG using the other API correctly. I've attached the WMF files that cause the code to throw this exception.
Thanks!
02-03-2009, 11:22 PM
163271
in reply to
163253
alcrus
Joined on 01-21-2004
Posts 4,457
Re: NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
Subscribe
Hello,
Thank you for the metafiles, we will investigate this issue and fix.
Alexey Zhilin
Team Leader
Aspose Tyumen Team
About Us
Contact Us
02-05-2009, 5:37 AM
163596
in reply to
163253
alcrus
Joined on 01-21-2004
Posts 4,457
Re: NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
Subscribe
We have published new Aspose.Metafiles 1.4 release.
You can download it
here
.
Alexey Zhilin
Team Leader
Aspose Tyumen Team
About Us
Contact Us
02-05-2009, 12:03 PM
163717
in reply to
163596
BrentP
Joined on 02-03-2009
Posts 3
Re: NegativeArraySizeException Converting WMF Files Using Version 1.3.3.0
Subscribe
I just validated that it works - thanks for such an amazingly fast turnaround on this!