Fork me on GitHub

OpenSeadragon 6.0.0

example: internet imaging procotol support

The Internet Imaging Protocol (IIP) is an API designed for efficient access to multi-resolution images over the internet. The query-string based API is flexible and extensible and allows various forms of image processing to be carried out server-side. The API was originally written by Hewlett Packard, Live Picture, Inc., and the Eastman Kodak Company for the (now defunct) International Imaging Industry Association (I3A). The last I3A-published version of the IIP specification was version 1.05, while information on the latest specification can be found on the IIPImage API documentation page.

OpenSeadragon supports the IIP API through a XMLHTTPRequest request. The IIP tile source accepts the following parameters:

OpenSeadragon supports the IIP API from version 6.0.0 onwards.

Basic Usage

A basic IIP tile source requires just 2 parameters: the API host end-point iipsrv and the image name image.

Basic Example
La Vierge au Diadème Bleu
Raphael / Giovanni Penni

Musée du Louvre
Copyright © 2024 C2RMF

Configuration is carried out via the tileSources option. The iipsrv parameter defines the API end-point and the image parameter defines the image file path and name on the host server.

OpenSeadragon({
  id:            "openseadragon-div",
  tileSources:   {
                   iipsrv: "/fcgi-bin/iipsrv.fcgi",
                   image: "test.tif"
                 }
});

Advanced Usage

In this advanced example, the tile format is explicitly requested as well as a transform consisting of a contrast enhancement with a color twist to perform channel recombination.

Advanced Example
96999 x 45667 pixel OME-TIFF
Paul Felts
OME-TIFF image repository
(Creative Commons 4.0)

Configuration is done via the tileSources option. The iipsrv parameter defines the API end-point and the image parameter defines the image file path and name on the host server. In this example, a JPEG tile format is explicitly requested (format: "jpg") and a transform is applied consisting of a contrast enhancement where each pixel value is multiplied by 1.5 (contrast: 1.5) together with a color twist which swaps the output red with the blue channel and renders the final blue channel as the sum of 0.9 multiplied by the original red + 0.1 multiplied by the original blue (twist: "[0,0,1; 0,1,0; 0.9,0,0.1]").

OpenSeadragon({
  id:            "openseadragon-div",
  showNavigator: true,
  tileSources:   {
                    iipsrv: "https://your.host/fcgi-bin/iipsrv.fcgi",
                    image: "images/test.tif",
                    format: "jpg",
                    transform: {
                      contrast: 1.5,
                      twist: "[0,0,1; 0,1,0; 0.9,0,0.1]"
                    }
                }
});