We get an error when generate a thumbnail for the some presentations:
class com.aspose.slides.pf4dd765c.pbdb106a0.f: Argument width or height cannot be less or equal to zero
Dimension we use is: new Dimension(50, 50)
PPT files are attached. Error fails for slide #6.
The full error file is attached.
Please advise of the root cause and what can we do to fix this issue.
I have worked with the presentation files shared by you using Aspose.Slides for Java 8.4.0 on my end. I have not been able to observe the issue specified. Can you please try using the specified version on your end and share with us if there is any issue incurring. Please share the environment details along with sample code if there is any issue incurring.
Please see attached slide #6 - Aspose fails to generate a thumbnail for it, we tried on Linux server and Windows server.
Yes we tried with 8.4.0
This is our code:
Presentation presentation = new Presentation (“path”);
Slide slide = presentation.getSlideByPosition(1);
Dimension dimension = new Dimension(50, 38);
slide.getThumbnail(dimension); // fails
I have verified the presentation, Overview_Express_Global_eng_20130828_wl - slide6.ppt on my end using Aspose.Slides for Java 8.4.0 with your code sample. I have been able to observe the issue specified on my end and have created an issue with ID SLIDESJAVA-34280 to further investigate and resolve it. This thread has been linked with the issue so that you may be automatically notified once the issue will be resolved.
I have also observed that if the following sample code is used, there is no rendering issue. You may please adopt the following code for the time being.
Slide sld = pres.getSlideByPosition(1);
BufferedImage image = sld.getThumbnail(1.0f, 1.0f);
ImageIO.write(image,“png”, new File(path+“Slides/”+presName+“Slide” + i + “.png”));
We are sorry for your inconvenience,