Mercurial > hg > digilib
comparison doc/src/site/markdown/iiif-api.md @ 1452:9429bb9c3a42
more IIIF API support (expose size of prescaled images).
author | robcast |
---|---|
date | Thu, 12 Nov 2015 16:43:01 +0100 |
parents | a244753f8f33 |
children | 1616ea719290 |
comparison
equal
deleted
inserted
replaced
1451:f0947c6190e6 | 1452:9429bb9c3a42 |
---|---|
1 # The digilib IIIF API | 1 # The digilib IIIF API |
2 | 2 |
3 The Scaler servlet provides not only its native [Scaler API](scaler-api.html) but also an API compliant to the standards of the International Image Interoperability Framework http://iiif.io. | 3 The Scaler servlet provides not only its native [Scaler API](scaler-api.html) but also an API compliant to the standards of the International Image Interoperability Framework http://iiif.io. |
4 | 4 |
5 As of version 2.3 digilib supports the [IIIF Image API version 1.1](http://iiif.io/api/image/1.1/) at [compliance level 2](http://iiif.io/api/image/1.1/compliance.html) (since V2.3.3 even for forced w,h sizes where the image will be distorted). | 5 As of version 2.3.6 digilib supports the [IIIF Image API version 2](http://iiif.io/api/image/2.0/) at [compliance level 2](http://iiif.io/api/image/2.0/compliance.html) (except bitonal quality). You can switch between API version 1.1 and 2.0 support with the `iiif-api-version` parameter in [digilib-config](digilib-config.html), |
6 | 6 |
7 IIIF Image API URLs for an image request have the form: | 7 IIIF Image API URLs for an image request have the form: |
8 | 8 |
9 http[s]://server/digilib-webapp/Scaler/iiif-prefix/identifier/region/size/rotation/quality[.format] | 9 http[s]://{server}/{digilib-webapp}/Scaler/{iiif-prefix}/{identifier}/{region}/{size}/{rotation}/{quality}.{format} |
10 | 10 |
11 where `digilib-webapp` is the name of the digilib web application in the servlet container. | 11 where `digilib-webapp` is the name of the digilib web application in the servlet container. |
12 | 12 |
13 The value of `iiif-prefix` is defined by the `iiif-prefix` parameter in the [digilib-config](digilib-config.html). The default value is "IIIF". | 13 The value of `iiif-prefix` is defined by the `iiif-prefix` parameter in [digilib-config](digilib-config.html). The default value is "IIIF". |
14 | 14 |
15 The `identifier` part of the URL must not contain slashes. Since the identifier is mapped to the digilib fn-parameter, which is a filesystem path that likely contains slashes separating subdirectories, all occurrences of a slash have to be replaced by the value of the `iiif-slash-replacement` parameter in [digilib-config](digilib-config.html). The default value of the replacement string is "!", so the fn-path "books/book1/page0002" becomes the identifier "books!book1!page0002". | 15 The `identifier` part of the URL must not contain slashes. Since the identifier is mapped to the digilib fn-parameter, which is a filesystem path that likely contains slashes separating subdirectories, all occurrences of a slash have to be replaced by the value of the `iiif-slash-replacement` parameter in [digilib-config](digilib-config.html). The default value of the replacement string is "!", so the fn-path "books/book1/page0002" becomes the identifier "books!book1!page0002". |
16 | 16 |
17 For a definition of the other request parameters `region`, `size`, `rotation`, `quality`, and `format` please see the [IIIF Image API docs](http://iiif.io/api/image/1.1/). | 17 For a definition of the other parameters `region`, `size`, `rotation`, `quality`, and `format` please see the [IIIF Image API docs](http://iiif.io/api/image/2.0/). |
18 | 18 |
19 A IIIF Image API image request URL could look like: | 19 A IIIF Image API image request URL could look like: |
20 | 20 |
21 http://www.example.org/digilib/Scaler/IIIF/books!book1!page0002/full/!150,75/0/native.jpg | 21 http://www.example.org/digilib/Scaler/IIIF/books!book1!page0002/full/!150,75/0/default.jpg |
22 | 22 |
23 An info request URL for the same image looks like: | 23 An info request URL for the same image looks like: |
24 | 24 |
25 http://www.example.org/digilib/Scaler/IIIF/books!book1!page0002/info.json | 25 http://www.example.org/digilib/Scaler/IIIF/books!book1!page0002/info.json |