Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!
png image rendred was empty |
Post Reply |
Author | |||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
Posted: 13 Feb 17 at 1:19PM |
||
Hi,
I'm using QuickPDFNet1212x64 library and when i call DARenderPageToFile method with the following params 1476395009, 1476395011, 5, 300, "C:\PageRender_0001.png" i got an empty image despite that, the returned result value is 1 =>
The pdf and generated image is located here: http://www.4shared.com/folder/6PUqQHD3/QuickPdf.html |
|||
tfrost
Senior Member Joined: 06 Sep 10 Location: UK Status: Offline Points: 437 |
Post Options
Thanks(0)
|
||
You should show your actual code to enable people to see how you obtained the filehandle and pageref parameters: the actual values are of no help. Then I expect someone will be able to suggest something to try.
|
|||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
|
||
I using this method to get filehandle
QuickPDFNet.PDFLibrary.Instance.DAOpenFileReadOnly( pdfFileFullPath, password ); and for the other parmameter pagehandle int pagehandle = QuickPDFNet.PDFLibrary.Instance.DAFindPage( fileHandle, pageNumber ); int result = QuickPDFNet.PDFLibrary.Instance.DARenderPageToFile ( fileHandle , pagehandle , GetPageRenderQuickPDFImageFormat( renderImageFormat ) , dpi , imageFile.FullName ); switch( result ) { case 0: //Wrong file handle or page handle { throw new ArgumentException( "Invalid page number or pdf file specified !" ); } case 1: { return imageFile; } case 2: //Cannot save to disk { throw new IOException( string.Concat( "Cannot save the page image rendering to ", pdfPageRenderImageFile, " !" ) ); } default : { throw new Exception( string.Concat( "Unknow quickpdf return code : ", result ) ); } |
|||
Ingo
Moderator Group Joined: 29 Oct 05 Status: Offline Points: 3524 |
Post Options
Thanks(0)
|
||
png and pdf-page are looking the same for me (using Chrome)?
Cheers and welcome here, Ingo |
|||
Cheers,
Ingo |
|||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
|
||
@Ingo: Yes they look like using chrome browser. You can download files as zip and you will see the difference
|
|||
Ingo
Moderator Group Joined: 29 Oct 05 Status: Offline Points: 3524 |
Post Options
Thanks(1)
|
||
The strange download site is not particularly trusting.
I don't wanna have few unknown things on my harddisk after using this site :( |
|||
Cheers,
Ingo |
|||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
|
||
think you Ingo I shared the pdf and the generated image in google drivehttps://drive.google.com/open?id=0B7zZhKfGfiFNWnBUa3RYTENybms |
|||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
|
||
I even tested with the new version and I had the same problem
|
|||
tfrost
Senior Member Joined: 06 Sep 10 Location: UK Status: Offline Points: 437 |
Post Options
Thanks(0)
|
||
I successfully converted this PDF file to image using our application, but (a) we convert to BMP, and (b) we no longer use the DA functions (which had some rendering issues with PDFium in the latest build, though we no longer use the Debenu PDFium DLL), and (c) we use Delphi, not .Net. But this confirms to me that there is nothing unusual or 'difficult' about your PDF file. I also tried to convert to PNG using Debenu PDF Tools Pro v3, but this was a 2014 version so based on a much earlier QPDF library: it crashed, but that has happened before.
I recommend trying the non-DA API functions to see if that helps. As I said, there are some differences in rendering between the two function sets in the latest release. If it works without DA but the DA functions are essential for you, then raise a support issue.
|
|||
Edysoft
Beginner Joined: 13 Feb 17 Location: France Status: Offline Points: 7 |
Post Options
Thanks(0)
|
||
I have already used another method than "DARenderPageToFile"(RenderDocumentToFile) but it does not work because it generate an empty image
|
|||
Ingo
Moderator Group Joined: 29 Oct 05 Status: Offline Points: 3524 |
Post Options
Thanks(0)
|
||
Mmmmmh...
In your code snippet i can't find the unlock-function? |
|||
Cheers,
Ingo |
|||
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |
Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. About — Contact — Blog — Support — Online Store