WPF: TIFF images with JPEG compression?

I have a large number of TIFF images that Id should use in a WPF program (specifically for .NET 3.5 SP1 and using C #). Half of the TIFF files contain color images encoded using JPEG compression, and they do not work with WPF. The Microsoft Office Document Imaging application processes the files in order. Since they really don’t like the OS itself (for example, it cannot create thumbnails). Assuming this is a limitation in the standard Windows Imaging Components (WIC) component libraries.

Does anyone have any ideas on reading TIFF images that use JPEG compression with the standard .NET / WPF libraries?

Or does anyone know of any alternative third-party TIFF codecs for WIC that I could use to solve this problem?

Or finally, are there alternative .NET libraries for TIFF files that are still easy to use with WPF?

Thanks!

+4
source share
3 answers

TIFF-wrapped files are presented in two variants - type 6 and type 7. What you describe is TIFF type 6. Although Adobe recommends that this type not be used for several years (see Tech Note 2 ), several graphic packages still use it.

I know several commercial graphics packages for .NET that can read them, for example, Captiva ISIS PixTools (formerly Pixtran), but I don’t know anything open source or otherwise free.

+1
source

What WPF API do you use to process them?

Have you tried using TiffBitmapDecoder from the System.Windows.Media.Imaging namespace?

+1
source

You will need to upgrade to Windows 7, Windows Server 2008 (or later) to open these files natively.

Libtiff (C ++) and LibTIFF.NET (.Net) should be able to open these files. Make sure that when you create one of these libraries, TIFF_JPEG (both 6 and 7) are included in the assembly. These formats are disabled in the default settings.

+1
source

All Articles