Loss of quality in images generating a pdf export

Stimulsoft Reports.NET discussion
Post Reply
jcolan
Posts: 1
Joined: Mon Apr 02, 2018 10:17 am

Loss of quality in images generating a pdf export

Post by jcolan »

Hi!!

I'm trying to generate a report just using a header and an image that i recieve in a POST request in .NET.

The image size that i send to the report is 56Kb

And the pdf generated size is 8676 Kb with a loss of quality in the image.

Is there any way to avoid the processing made by the report. I would like to know how to get a report that shows the same image with the same quality I send to it.

We use this code to create the byte[] returned as pdf file in a HttpResponse

Code: Select all

public static byte[] CreateArrBytes(this StiReport report, float imageResolution = 3000)
{
            using (var memoryStream = new MemoryStream())
            {
                var pdfSettings = new StiPdfExportSettings { EmbeddedFonts = true, ImageResolution = imageResolution };
                report.ExportDocument(StiExportFormat.Pdf, memoryStream, pdfSettings);
                return memoryStream.ToArray();
            }
}
Thanks
Attachments
pdf example image printing.zip
Pdf generated
(683.79 KiB) Downloaded 250 times
image sent to the report
image sent to the report
Captura2.PNG (55.27 KiB) Viewed 1950 times
Lech Kulikowski
Posts: 7345
Joined: Tue Mar 20, 2018 5:34 am

Re: Loss of quality in images generating a pdf export

Post by Lech Kulikowski »

Hello,

Please try to check the last version.

If the issue still present, please send us a simple report with test data for analysis.

Thank you.
Post Reply