Low quality when converting pdf format file to tiff format file when compress type is CCITT4 or CCITT3

Hi Aspose Team, when I use the aspose pdf to convert pdf format file to tiff format file. If the compress type is CCITT4 or CCITT3. The definition of generated file is very low.

Here is the pdf file.
meeting test2.pdf (272.8 KB)
Here is the generated file.
meeting test.tiff.zip (30.4 KB)

You can see that the text on the calendar is not clear.

My aspose pdf version is 23.6. My platform is Macos 13.4.1. (I have test it on centos, the result is the same)

My test code is here.

    private static void exeConvert(String sourceFile, String targetFile) throws Exception {
        // Open document
        Document pdfDocument = new Document(sourceFile);

        // Create stream object to save the output image
        java.io.OutputStream imageStream = new java.io.FileOutputStream(targetFile);

        // Create Resolution object
        Resolution resolution = new Resolution(200,200);

        // instantiate TiffSettings object
        TiffSettings tiffSettings = new TiffSettings();
        // set the compression of resultant TIFF image
        tiffSettings.setCompression(CompressionType.CCITT4);
        // set the color depth for resultant image
        tiffSettings.setDepth(ColorDepth.Format8bpp);
        // skip blank pages while rendering PDF to TIFF
        tiffSettings.setSkipBlankPages(true);
        // for test
//        tiffSettings.setUseAlternativeImageEngine(true);

        // Create TiffDevice object with particular resolution
        double width = pdfDocument.getPages().get_Item(1).getRect().getWidth();
        double height = pdfDocument.getPages().get_Item(1).getRect().getHeight();
        TiffDevice tiffDevice = new TiffDevice(1728, (int) (height / width * 1728), resolution, tiffSettings);
        // Convert a all pages of PDF file to TIFF format
        tiffDevice.process(pdfDocument, imageStream);

        // Close the stream
        imageStream.close();
    }

    public static void main(String[] args) throws Exception {
        String targetFile = "test.tiff";
        File file = new File(targetFile);
        file.getParentFile().mkdirs();
        exeConvert("test2.pdf", targetFile);
    }

For some reason, we have to use the compress type CCITT4 or CCITT3. Is there a way to improve the quality of generated tiff file?

@jessetest

Is it possible for you to provide a sample expected output TIFF for our reference? We will investigate the feasibility to generate similar output using the API and share our feedback with you.

Yes. We expect output TIFF file has at least the same quality as this one.

7254814042054885553.tiff.zip (307.8 KB)

@jessetest

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-55041

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.

@jessetest

With CompressionType.CCITT4, setting ColorDepth.Format8bpp does not work, it will still be Format1bpp.

Also, you can adjust the brightness relative to which the original image will be divided into black and white.

To do this, please use the option tiffSettings.Brightness = XX; , where XX is a number from 0.01f to 0.99f.

The number is selected experimentally depending on the brightness of the original image and the required amount of detail in the output image.