[ https://issues.apache.org/jira/browse/PDFBOX-5956?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17927133#comment-17927133 ]
Tilman Hausherr commented on PDFBOX-5956: ----------------------------------------- {code:java} InputStream is = new URI("https://issues.apache.org/jira/secure/attachment/13074744/path.txt").toURL().openStream(); Scanner scanner = new Scanner(is); scanner.useLocale(Locale.US); //https://stackoverflow.com/a/5929135/535646 GeneralPath path = new GeneralPath(); path.moveTo(scanner.nextDouble(), scanner.nextDouble()); int count = 0; while (scanner.hasNextDouble()) { path.lineTo(scanner.nextDouble(), scanner.nextDouble()); ++count; } System.out.println("calling 'new Area(path)' with path of " + count + " lines"); new Area(path); System.out.println("OK"); {code} > renderImageWithDPI causes OutOfMemoryError > ------------------------------------------ > > Key: PDFBOX-5956 > URL: https://issues.apache.org/jira/browse/PDFBOX-5956 > Project: PDFBox > Issue Type: Bug > Components: Rendering > Affects Versions: 2.0.33, 3.0.4 PDFBox > Reporter: Andreas Koch > Priority: Major > Attachments: path.txt, sensors-21-04255.pdf_20.pdf > > > > {code:java} > Path path = Paths.get("sensors-21-04255.pdf_20.pdf"); > PDDocument doc = Loader.loadPDF(path.toFile()); > PDFRenderer renderer = new PDFRenderer(doc); > BufferedImage image = renderer.renderImageWithDPI(0, 72, ImageType.RGB); > {code} > Heap was limited to 8 GB. > -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org For additional commands, e-mail: dev-h...@pdfbox.apache.org