These functions use information from scandata.xml to determine size and url for each page.īecause web browsers generally cannot display JPEG2000 images, a piece of code called BookReaderImages.php performs on-the-fly JPEG2000 to JPEG conversion on the cluster. Also, since some pages are not supposed to be displayed, the getPageURI() function maps an "index number" that the book reader uses to a "leaf number" that corresponds to an image in the jp2.zip file. The raw images, the cropped and deskewed images, and the scandata.xml file are available for each book on .īecause crop boxes can vary between pages for Internet Archive books, the getPageWidth() and getPageHeight() functions can return a different size for each image in the book. The cropped and deskewed images are stored in JPEG 2000 format in a zip file called bookid_jp2.zip. This information is also stored in scandata.xml. During this process, some images, such as color cards, white cards, and tissue paper pages, are marked as pages that should not be displayed. The size of the cropped image is stored in a file called scandata.xml. During the book scanning process, each page is imaged using a high-resolution digital camera, and then each page is cropped and deskewed. Scaling is done in the web browser.įor books scanned by the Internet Archive and stored on, bookreader operation is a bit more complex. The images are all the same size, and two functions in BookReaderJSSimple.js, getPageWidth() and getPageHeight(), return the page size. Images are numbered sequentially and stored in a directory called "StandAloneImages". In the case of the Standalone Demo, operation is fairly simple. Works with a variety of image servers, or a simple directory of images Support for foldouts and variable page size for Yiddish and Chinese)įull-text search with highlighting of search results Single-Page, Two-page, and Thumbnail view You can also link to a specific page and specify that two-page mode should be used: To use your own images you would modify BookReaderJSSimple.js to connect the BookReader with your book's page images and metadata.įor books hosted on the Internet Archive the BookReader can be embedded on any site that allows you to add an iframe, for example using the code below. Once you've downloaded the source code you can open BookReaderDemo/index.html in your web browser and you should see an example book.
0 Comments
Leave a Reply. |