I tried converting slides into png. It exported png, but the exported png contains only background. It is not rendering text in it, also the exported background scale is too big that only 1/4 of the image is rendered as png. Attached is the PPTX and the java code I am using. //java code FileInputStream is = new FileInputStream("KEY02.pptx"); XMLSlideShow ppt = new XMLSlideShow(is); is.close(); Dimension pgsize = ppt.getPageSize(); XSLFSlide[] slide = ppt.getSlides(); for (int i = 0; i < slide.length; i++) { BufferedImage img = new BufferedImage(pgsize.width, pgsize.height, BufferedImage.TYPE_INT_RGB); Graphics2D graphics = img.createGraphics(); //clear the drawing area graphics.setPaint(Color.white); graphics.fill(new Rectangle2D.Float(0, 0, pgsize.width, pgsize.height)); //render slide[i].draw(graphics); //save the output FileOutputStream out = new FileOutputStream("slide-" + (i + 1) + ".png"); javax.imageio.ImageIO.write(img, "png", out); out.close(); }
It is more than 2 mb. So I have uploaded PPTX it to my dropbox. https://www.dropbox.com/s/j52s2e6a4eieavh/KEY02.pptx
When I save it as powerpoint 97-2004 format, and use HSFL module to render png, it works like a charm.
Fixed as part of r1694925 this contains also other rendering fixes, a common SlideFactory and PPTX2PNG also handles .ppt now the rendering still doesn't support wmf, so the logo in the lower right corner is not rendered the text on the slide had actually a gradient fill, therefore it was rendered black (default) up till now