Noise points when converting PDF to JPG in C#

Hi,
I got noise points when I try to convert pdf to jpg.

Tested OSs were Win7 and Win10
.NET target platform is .net 6.0
Using SDK: Aspose.PDF for .Net 24.6

Test code

void testToJpg(string filename)
{
    // Load document
    Document srcFile = new Document(filename);

    using (FileStream streamObj = new FileStream(filename+".out.jpg", FileMode.Create))
    {

        // Create Resolution object
        Resolution resolution = new Resolution(300);

        // Create Image device with specified attributes
        // Width, Height, Resolution
        JpegDevice renderToImages = new JpegDevice(500, 700, resolution);
        // For BMP, PNG, TIFF it will be BmpDevice, PngDevice, TiffDevice respectively

        // Convert a particular page and save the image to stream
        renderToImages.Process(srcFile.Pages[1], streamObj);

        // Close stream
        streamObj.Close();
    }
}

罐类业绩-26页.7z (53.4 KB)

@kngstr
We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s): PDFNET-57568

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

@kngstr
the development team reports

When using Aspose.Pdf.Drawing version 24.09 the resulting image is noise free.

I checked, it really is.
57568_out.jpg (212.6 KB)

I got still the same noisepoint with 24.9.
Did you test with the code above?

@kngstr
Are you using Aspose.Pdf.Drawing (not Aspose.Pdf)?

No, I’m using JpegDevice.
So, JpegDevice is not recommanded?
Should I change to Aspose.Pdf.Drawing?

@kngstr
Please look at my latest messages in these threads and write again if you have questions.

@sergei.shibanov

OK. I got Aspose.Pdf.Drawing is a new library.
But I was wondering if Aspose.Pdf can deal with this file?

@kngstr
As far as I remember, the problem with Aspose.Pdf remained. But since in the future it is planned to use the variant with Drawing as the main and only one, the developers decided that the task can be closed.

@sergei.shibanov OK, Thanks.

The issues you have found earlier (filed as PDFNET-57568) have been fixed in Aspose.PDF for .NET 24.10.