Spire.PDF is a professional PDF library applied to creating, writing, editing, handling and reading PDF files without any external dependencies. Get free and professional technical support for Spire.PDF for .NET, Java, Android, C++, Python.

Fri Jul 22, 2016 6:13 am

Then we save a PDF to an image (Bitmap and Metafile) some objects are schuffled / displaced.

Here is the code:

Code: Select all
var pdfDocument = new Spire.Pdf.PdfDocument();
pdfDocument.LoadFromFile(pdfFileName);
var pdfPageAsPng = (Bitmap)pdfDocument.SaveAsImage(pageNumber - 1, PdfImageType.Bitmap);
pdfPageAsPng.Save(@"C:\temp\test.png", ImageFormat.Png);


Attached the source PDF and destination PNG. We tested this with Version 3.7.0.5041.
Last edited by MSPchristian on Fri Jul 22, 2016 9:02 am, edited 1 time in total.

MSPchristian
 
Posts: 2
Joined: Thu Jul 21, 2016 3:03 pm

Fri Jul 22, 2016 7:18 am

Hi,

Thanks for your inquiry.
I have noticed your issue and posted it to our Dev team. Once there is any progress, we will inform you.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Fri Aug 12, 2016 6:15 am

Hi,

Thanks for your waiting.
Now we release Spire.PDF Pack(Hot Fix) Version:3.7.198 which resolves the issue you mentioned, welcome to test it.
If there is any question, please let us know.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Wed Aug 17, 2016 8:20 am

Yes, the issue is fixed. Many thanks.

Is a hotfix for Free Spire.PDF also planned?

MSPchristian
 
Posts: 2
Joined: Thu Jul 21, 2016 3:03 pm

Wed Aug 17, 2016 8:29 am

Hi,

Thanks for your feedback.
Sorry that we don't have a plan to update Free version at present. Please feel free to contact us again for further question, we are here for help.

Sincerely,
Betsy
E-iceblue support team
User avatar

Betsy
 
Posts: 802
Joined: Mon Jan 19, 2015 6:14 am

Tue Jun 09, 2020 6:56 am

Hi,

I'm encountering the same issue in FreeSpire.PDF 6.2.0. Has this not been fixed yet for the free version?

I'm are running my .NET Core 3.x application inside a Linux Docker container (aspnetcore image, Debian based OS) and thats where I have this issue. If I run the exact same application on a Windows host, it works perfectly.

Code snippet:
Code: Select all
using var pdfDocument = new PdfDocument();
pdfDocument.LoadFromBytes(pdfData);
using var image = pdfDocument.SaveAsImage(index, PdfImageType.Bitmap);
using var ms= new MemoryStream();
image.Save(ms, ImageFormat.Png);


Thank you very much.

Best regards
Patrick

patrick.weibel
 
Posts: 5
Joined: Tue Jun 09, 2020 6:21 am

Tue Jun 09, 2020 8:40 am

Hi Patrick,

Thanks for your inquiry.
To help us investigate your issue more accurately and quickly, please provide your input file, your output image as well as your dockerfile. You could upload them here or send them to us(support@e-iceblue.com) via email. Thanks in advance.

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Tue Jun 09, 2020 11:10 am

Hi Rachel,

Thank you very much for the quick response. I sent you an email due to the size limitation for the file upload.

Best regards,
Patrick

patrick.weibel
 
Posts: 5
Joined: Tue Jun 09, 2020 6:21 am

Tue Jun 09, 2020 4:19 pm

Hi Rachel,

Meanwhile I've tested several things.

First of all, I can reproduce the same issue by using the commercial version of Spire.PDF 6.5.15, so it does not seem to be a problem on the free version only.

At first glance I thought it could propably be an issue with the Save-operation on "System.Drawing.Image" and the underlying libgdiplus library or perhaps an issue reading the PDF document from the byte array / stream. But during testing I've isolated both, the reading as well as the Save-operation and they seem to work properly.

So my best guess at the moment is that the issue might be somewhere between the PDF->Image conversion.

I hope this helps for your further analysis.

Thank you very much.

Best regards,
Patrick

patrick.weibel
 
Posts: 5
Joined: Tue Jun 09, 2020 6:21 am

Wed Jun 10, 2020 11:00 am

Hi Patrick,

Thanks for providing your files via email.
We are now configuring the test environment for further testing and I will give you an feedback ASAP.

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Thu Jun 11, 2020 6:27 am

Hi Patrick,

I have reproduced your issue on my side and logged it into our bug tracking system with the ticket SPIREPDF-3327. Our Dev team will investigate further and fix it. If there is any update, we will let you know.
Apologize for the inconvenience caused.

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Thu Jun 11, 2020 7:16 am

Hi Rachel,

Thank you very much for your support. Will you release a fix for both, the commercial as well as the free version?

Best regards,
Patrick

patrick.weibel
 
Posts: 5
Joined: Tue Jun 09, 2020 6:21 am

Thu Jun 11, 2020 7:49 am

Hi Patrick,

Thanks for your reply.
Sorry we only upgrade our free version irregularly. If this issue is resolved, we will first release a commercial version that contains its fix.
If you have further questions, please feel free to let us know.

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Mon Jul 13, 2020 12:12 pm

Hi Rachel,

Has this issue been fixed?

Best regards,
Patrick

patrick.weibel
 
Posts: 5
Joined: Tue Jun 09, 2020 6:21 am

Tue Jul 14, 2020 1:36 am

Hi Patrick,

Thanks for your following up.
Sorry to tell you that our Dev team is still fixing this issue due to its complexity. I have requested them to share any possible ETA at their earliest time. Once there is any good news, we will inform you immediately. Apologize for the inconvenience caused.

Sincerely,
Rachel
E-iceblue support team
User avatar

rachel.lei
 
Posts: 1571
Joined: Tue Jul 09, 2019 2:22 am

Return to Spire.PDF