I need to view Multipage TIFF in a WPF application

I need to view multi-page tiff with WPF.

I currently have the following:

<FlowDocumentReader>
    <FlowDocument>
        <BlockUIContainer>
            <Image x:Name="DocImg" Source="test1752158790.tif" />          
        </BlockUIContainer>
    </FlowDocument>
</FlowDocumentReader>

I can only view the first page.

Is there any way to do this?

Thank! Todd

+3
source share
2 answers

I would execute my own control code in reverse order. You will need some user input to indicate when the user goes from one page to another, whether with a mouse click or something else.

tiff. , ChrisF, libtiff, ,.NET- FreeImage, tiff .NET.

+3

, TiffBitmapDecoder.

- :

// Decode TIFF image
ImageStream = new FileStream(EnvelopeItem.LocalImagePath, FileMode.Open, FileAccess.Read, FileShare.Read);
ImageDecoder = new TiffBitmapDecoder(ImageStream, BitmapCreateOptions.PreservePixelFormat, BitmapCacheOption.Default);
PageImage.Source = ImageDecoder.Frames.FirstOrDefault();

, .

+3

Source: https://habr.com/ru/post/1743835/


All Articles