• Post Reply Bookmark Topic Watch Topic
  • New Topic

Convert PDF to Image by specifying page range using JPedal  RSS feed

 
Nitesh Golchha
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

Is there a way to convert PDF to jpeg images using JPedal by specifying the page range?

Any help will be much appreciated.

Thanks,
Nitesh
 
Tim Moores
Saloon Keeper
Posts: 4036
94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure about JPedal, but PDFBox can do that: http://pdfbox.apache.org/commandlineutilities/PDFToImage.html
 
Nitesh Golchha
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Tim,

I did try PDFBox but the issue with it is that it does not let you resize the images to storyboard size which is currently my project's requirement. I want to create 200*157 size jpegs from PDFs with specified page range. JPedal does give me that size but I want to implement the page range feature too. Thanks for your reply any way.
 
Tim Moores
Saloon Keeper
Posts: 4036
94
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What prevents you from resizing the images to whatever size you fancy after you have extracted them from the PDF?
 
Nitesh Golchha
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes, resizing can be done after the image generation, I realized that today. But PDFBox does not handle PDFs with different types of images embedded in it. I get this exception when I try to create images from PDF that contains images:-

java.io.IOException: Not implemented
at org.apache.pdfbox.pdmodel.graphics.color.PDCalGray.createColorSpace(PDCalGray.java:100)

Seems like they have not implemented some methods yet so I am forced to look into other options.

Thanks,
Nitesh
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!