Posted 18 May 2022, 1:33 am EST
My company considering to buying GrapeCity Documents for PDF library.
One of the feature we need is the compression of the pdf files.
I made quick test. І wrote code :
var pdfDocument = new GcPdfDocument();
pdfDocument.Load(inputStream);
pdfDocument.PdfVersion = "1.6";
pdfDocument.ImageOptions.CompressColors = true;
pdfDocument.ImageOptions.JpegQuality = 1;
pdfDocument.ImageOptions.Format = ImageOptions.ImageFormat.Auto;
pdfDocument.CompressionLevel = System.IO.Compression.CompressionLevel.Optimal;
pdfDocument.FontEmbedMode = FontEmbedMode.NotEmbed;
pdfDocument.Save(outputStream, SaveMode.Linearized);
… and try compress different files. The size of the file after “compression” is the same or even greater.
Can You help me with this? There are possibility to edit the embedded images? I’m thinking about the resolution’s change or/and convert image to greyscale.
Can I copy only images and texts from one pdf to another without attachments, notes and so on?