Ladies and gentlemen.
when converting pdf fils to tif using aspose.pdf
public override void ConvertAndCreateSingleFile(string source, string outputImageFile, int xDpi = 300,
int yDpi = 300)
{
if (!AsposeLibrary.InitPdfLicense())
{
throw new Exception(“Aspose licence cannot be obtained !!”);
}
var pdfdocument = new Document(source) {DisplayDocTitle = true};
var resolution = new Resolution(xDpi);
var tiffSettings = new TiffSettings
{
Compression = CompressionType.CCITT4,
Depth = ColorDepth.Format8bpp,
Shape = ShapeType.Portrait,
SkipBlankPages = false,
Brightness = 0.9f
};
var tiffDevice = new TiffDevice(resolution, tiffSettings);
tiffDevice.Process(pdfdocument, outputImageFile);
if (File.Exists(outputImageFile))
{
this.LastConversionWasSuccessful = true;
}
}
Normally ther is no problem.
But once in a while the method produces hieroglyphs. (unreadyble garbage)
I tried with Aspose.pdf version 17.9
9873d55d-271d-419a-a607-bbdf82a8d9f6.0.pdf (145.4 KB)
I anylyzed he file in question with help of the aspose.validate method and there are only few error.
Oher fiels, with more errors are rendered successfully.
Kind regards
Martin Hock