Bug 54814 - Unable to create thumbs for a specific PowerPoint file
Summary: Unable to create thumbs for a specific PowerPoint file
Status: RESOLVED LATER
Alias: None
Product: POI
Classification: Unclassified
Component: XSLF (show other bugs)
Version: 3.9-FINAL
Hardware: PC All
: P2 normal (vote)
Target Milestone: ---
Assignee: POI Developers List
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-04-08 12:14 UTC by DagHendrik
Modified: 2016-03-23 22:06 UTC (History)
1 user (show)



Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description DagHendrik 2013-04-08 12:14:23 UTC
I'm running the draw method on a XSLFSlide object with a Graphics2D object as input like this:

pptxSlides[startSlide+i].draw(graphics);	

It normally works fine, but on some PPTs, like this one: http://dl.dropbox.com/u/3557862/test3.pptx i get an error (see below).

The file can opens fine in PowerPoint 2010.
 


Could not write thumbs
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
	at org.apache.poi.xslf.usermodel.RenderableShape.createLinearGradientPaint(RenderableShape.java:239)
	at org.apache.poi.xslf.usermodel.RenderableShape.selectPaint(RenderableShape.java:123)
	at org.apache.poi.xslf.usermodel.RenderableShape.getPaint(RenderableShape.java:336)
	at org.apache.poi.xslf.usermodel.XSLFBackground.getPaint(XSLFBackground.java:70)
	at org.apache.poi.xslf.usermodel.XSLFBackground.draw(XSLFBackground.java:53)
	at org.apache.poi.xslf.usermodel.XSLFSlide.draw(XSLFSlide.java:218)
	at ThreadWithResult.run(ThreadWithResult.java:104)
Caused by: java.lang.reflect.InvocationTargetException
	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
	at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
	at java.lang.reflect.Constructor.newInstance(Unknown Source)
	at org.apache.poi.xslf.usermodel.RenderableShape.createLinearGradientPaint(RenderableShape.java:233)
	... 6 more
Caused by: java.lang.IllegalArgumentException: Keyframe fractions must be increasing: 1.0
	at java.awt.MultipleGradientPaint.<init>(Unknown Source)
	at java.awt.LinearGradientPaint.<init>(Unknown Source)
	... 11 more
Comment 1 Andreas Beeker 2016-01-24 00:30:26 UTC
Please attach the test file to the bug entry or email it to me, if it's to 
large to attach.
Comment 2 Andreas Beeker 2016-03-23 22:06:10 UTC
There are still a heaps of rendering issues, which I fix one after another,
but regarding this entry I'm closing this for now ... feel free to reopen it 
with a new linked ppt.
Furthermore I've fixed some of the gradient handling - maybe this case falls 
under it ...