Giter VIP home page Giter VIP logo

zoom-images's Introduction

POC for the Image Zooming

Prerequisites

DEEP Zoom setup

  • Create storage account and enable static web site docs

Split TIFF to DeepZoom Format

  • Install vips tool in Linux or WSL
sudo apt install libvips
sudo apt install libvips-tools
  • Run vips dzsave to prepare image
vips dzsave HR11-1075-S11-31517-1D.tiff slides

It will generate *.dzi and multiple layers tile images

  • Load all resulting tiles into storage account in $web container

docs

Prepare Web Page with OpenSeadragon

Follow OSD GetStarted and create index.html pointing tileSources to slides in DZI format and prefixUrl to the images coming with openseadragon library:

 <div class="demoarea">
        <div class="demoheading">
            OpenSeadragon Viewer With Default Settings
            <span id='consolelog'></span>
        </div>
        <div id="contentDiv" class="openseadragon"></div>
     </div>
    
    <script type="text/javascript">
        // Example
        OpenSeadragon({
            id:              "contentDiv",
            prefixUrl:       "/openseadragon-2.4.2/images/",
            tileSources:     "/slides.dzi",
            visibilityRatio: 1.0,
            constrainDuringPan: true
        });
    </script>
  • Navigate to primary endpoint for static website

IIIF setup

  • Replace url in docker/cantaloupe.properties file to point to Azure Storage Static Web Site Primary endpoint (shown above) where TIFF file stored
HttpSource.BasicLookupStrategy.url_prefix = https://url>.web.core.windows.net/tiff/
cd docker
az acr build --registry <name of ACR> --image cantaloupe:5.0.2 .
  • Create Azure Web App and deploy Cantaloupe Container docs

docs

  • Set webapp configuration WEBSITES_PORT to port exposed by docker image docs

  • Start Web app and havigate to its URL docs

  • To validate IIIF server navigate to image URL

https://<url>.azurewebsites.net/iiif/3/HR11-1075-S11-31517-1D.tiff/info.json
  • Create indexiiif.html and upload it to the Storage Account, where tileSources should point to IIIF Server url hosting the image:
<div class="demoarea">
        <div class="demoheading">
            OpenSeadragon Viewer With Default Settings
            <span id='consolelog'></span>
        </div>
        <div id="contentDiv" class="openseadragon"></div>
     </div>
    
    <script type="text/javascript">
        // Example
        OpenSeadragon({
            id:              "contentDiv",
            prefixUrl:       "/openseadragon-2.4.2/images/",
            visibilityRatio: 1.0,
            constrainDuringPan: true,
            sequenceMode:       true,
            tileSources: ["https://<url>.azurewebsites.net/iiif/3/HR11-1075-S11-31517-1D.tiff/info.json"],
            "tiles": [{
                "scaleFactors": [ 1, 2, 4, 8, 16, 32, 64 ],
                "width": 1024
                }]
        });
    </script>

zoom-images's People

Contributors

lenisha avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.