[jira] [Updated] (PDFBOX-4110) PDF to JPG conversion is returning distorted images

2018-02-14 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4110?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4110:

Labels: JBIG2 jbig2  (was: )

> PDF to JPG conversion is returning distorted images
> ---
>
> Key: PDFBOX-4110
> URL: https://issues.apache.org/jira/browse/PDFBOX-4110
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 1.8.11
>Reporter: Avinash
>Priority: Blocker
>  Labels: JBIG2, jbig2
> Attachments: 1000-test-1.jpg, 1000-test-2.jpg, 
> 347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf, flight_receipt.pdf
>
>
> Hello,
> We are using PDFBox-1.8.11 to convert PDFs to JPG images in our project.
> The conversion is working fine for some PDFs but for some of the PDFs, the 
> converted images in JPG format seems to be distorted (esp, flight itenary 
> PDFs).  An example of PDF is attached to this ticket for your reference 
> [347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf].
> When this PDF is converted to JPG using PDFbox API, the image returned seems 
> to be corrupted with weird characters.
>  
> Below is the code we are using for PDF to JPG conversion.
> Kindly help us to find out how this issue can be resolved. Thank you !
>  
> public String convertPDFtoJPG(String source , String filepath1, String 
> filePath2, IqiArInvoiceEventSourceVO arInvoiceEventSourceVO ) throws 
> BaseECapException{
>  
>  String newFile="";
>  
>  //IPM-5181
>  String filePathDelimiter = ";";
>  ArrayList filepaths = new ArrayList();
>  
>  {color:#FF}_try{_{color}
> {color:#FF} _PDDocument doc=PDDocument.load(new 
> FileInputStream(source));_{color}
> {color:#FF} _List 
> pages=doc.getDocumentCatalog().getAllPages();_{color}
> {color:#FF} _Iterator i= pages.iterator();_{color}
>  
> {color:#FF} _int count=1;_{color}
> {color:#FF} _while(i.hasNext()){_{color}
> {color:#FF} _PDPage page=i.next();_ {color}
> {color:#FF} _BufferedImage bi=page.convertToImage();_{color}
>  String saveFilePath = filepath1+filePath2;
>  
>  if (!new File(saveFilePath).exists()) {
>  new File(saveFilePath).mkdirs();
>  }
>  
> Thanks,
> Avinash



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4110) PDF to JPG conversion is returning distorted images

2018-02-14 Thread Tilman Hausherr (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4110?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Tilman Hausherr updated PDFBOX-4110:

Component/s: Rendering

> PDF to JPG conversion is returning distorted images
> ---
>
> Key: PDFBOX-4110
> URL: https://issues.apache.org/jira/browse/PDFBOX-4110
> Project: PDFBox
>  Issue Type: Bug
>  Components: Rendering
>Affects Versions: 1.8.11
>Reporter: Avinash
>Priority: Blocker
> Attachments: 1000-test-1.jpg, 1000-test-2.jpg, 
> 347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf, flight_receipt.pdf
>
>
> Hello,
> We are using PDFBox-1.8.11 to convert PDFs to JPG images in our project.
> The conversion is working fine for some PDFs but for some of the PDFs, the 
> converted images in JPG format seems to be distorted (esp, flight itenary 
> PDFs).  An example of PDF is attached to this ticket for your reference 
> [347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf].
> When this PDF is converted to JPG using PDFbox API, the image returned seems 
> to be corrupted with weird characters.
>  
> Below is the code we are using for PDF to JPG conversion.
> Kindly help us to find out how this issue can be resolved. Thank you !
>  
> public String convertPDFtoJPG(String source , String filepath1, String 
> filePath2, IqiArInvoiceEventSourceVO arInvoiceEventSourceVO ) throws 
> BaseECapException{
>  
>  String newFile="";
>  
>  //IPM-5181
>  String filePathDelimiter = ";";
>  ArrayList filepaths = new ArrayList();
>  
>  {color:#FF}_try{_{color}
> {color:#FF} _PDDocument doc=PDDocument.load(new 
> FileInputStream(source));_{color}
> {color:#FF} _List 
> pages=doc.getDocumentCatalog().getAllPages();_{color}
> {color:#FF} _Iterator i= pages.iterator();_{color}
>  
> {color:#FF} _int count=1;_{color}
> {color:#FF} _while(i.hasNext()){_{color}
> {color:#FF} _PDPage page=i.next();_ {color}
> {color:#FF} _BufferedImage bi=page.convertToImage();_{color}
>  String saveFilePath = filepath1+filePath2;
>  
>  if (!new File(saveFilePath).exists()) {
>  new File(saveFilePath).mkdirs();
>  }
>  
> Thanks,
> Avinash



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org



[jira] [Updated] (PDFBOX-4110) PDF to JPG conversion is returning distorted images

2018-02-14 Thread Avinash (JIRA)

 [ 
https://issues.apache.org/jira/browse/PDFBOX-4110?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Avinash updated PDFBOX-4110:

Attachment: flight_receipt.pdf
1000-test-2.jpg
1000-test-1.jpg

> PDF to JPG conversion is returning distorted images
> ---
>
> Key: PDFBOX-4110
> URL: https://issues.apache.org/jira/browse/PDFBOX-4110
> Project: PDFBox
>  Issue Type: Bug
>Affects Versions: 1.8.11
>Reporter: Avinash
>Priority: Blocker
> Attachments: 1000-test-1.jpg, 1000-test-2.jpg, 
> 347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf, flight_receipt.pdf
>
>
> Hello,
> We are using PDFBox-1.8.11 to convert PDFs to JPG images in our project.
> The conversion is working fine for some PDFs but for some of the PDFs, the 
> converted images in JPG format seems to be distorted (esp, flight itenary 
> PDFs).  An example of PDF is attached to this ticket for your reference 
> [347254-111788-437553AC1B68331C9B04E6D099E39CB5.pdf].
> When this PDF is converted to JPG using PDFbox API, the image returned seems 
> to be corrupted with weird characters.
>  
> Below is the code we are using for PDF to JPG conversion.
> Kindly help us to find out how this issue can be resolved. Thank you !
>  
> public String convertPDFtoJPG(String source , String filepath1, String 
> filePath2, IqiArInvoiceEventSourceVO arInvoiceEventSourceVO ) throws 
> BaseECapException{
>  
>  String newFile="";
>  
>  //IPM-5181
>  String filePathDelimiter = ";";
>  ArrayList filepaths = new ArrayList();
>  
>  {color:#FF}_try{_{color}
> {color:#FF} _PDDocument doc=PDDocument.load(new 
> FileInputStream(source));_{color}
> {color:#FF} _List 
> pages=doc.getDocumentCatalog().getAllPages();_{color}
> {color:#FF} _Iterator i= pages.iterator();_{color}
>  
> {color:#FF} _int count=1;_{color}
> {color:#FF} _while(i.hasNext()){_{color}
> {color:#FF} _PDPage page=i.next();_ {color}
> {color:#FF} _BufferedImage bi=page.convertToImage();_{color}
>  String saveFilePath = filepath1+filePath2;
>  
>  if (!new File(saveFilePath).exists()) {
>  new File(saveFilePath).mkdirs();
>  }
>  
> Thanks,
> Avinash



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

-
To unsubscribe, e-mail: dev-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: dev-h...@pdfbox.apache.org