My program, that converts a multi page TIFF to PDF is not longer working under Windows 7. The program contains code that walks through the pages of the TIFF, converts each page as TIFF with CCITT Group4 compression and inserts the bitmap data in the resulting PDF file.
Converting is done in the following way (c#):
ImageCodecInfo tiffCodecInfo = GetEncoderInfo("image/tiff");
EncoderParameters myEncoderParameters = new EncoderParameters(2);
// Save the bitmap as a TIFF file with CCITT group4 compression.
myEncoderParameters.Param[0] = new EncoderParameter System.Drawing.Imaging.Encoder.Compression, (long)EncoderValue..CompressionCCITT4);
myEncoderParameters.Param[1] = new EncoderParameter(System.Drawing.Imaging.Encoder.ColorDepth, 1L);
image.Save(source, tiffCodecInfo, myEncoderParameters);
It seems that the behaviour of GDI+ is changed in Windows 7: The resulting CCITT bitmap data is no longer encoded in a single strip. Because of this I cannot use this bitmap data in my PDF file.
Question: does anybody know how I can tell GDI+ to encode the bitmap data in a single strip?