@mboultoureau/annotorious-map-annotation
v0.3.3
Published
An Annotorious plugin for annotating maps
Downloads
4
Maintainers
Readme
Annotorious Map Annotation
A helper plugin for using Annotorious with maps and geo-referenced images. After the plugin is installed, annotation shapes will use geographic coordinates (latitude, longitude) rather than image pixel coordinates.
This plugin currently works with Annotorious OpenSeadragon and WMTS maps only.
The plugin depends on:
Installing
npm install @recogito/annotorious-map-annotation
or
<script src="https://cdn.jsdelivr.net/npm/@recogito/annotorious-map-annotation@latest/dist/annotorious-map-annotation.js"></script>
Using
// OpenSeadragon viewer
var viewer = OpenSeadragon({
id: "openseadragon",
prefixUrl: "openseadragon/images/"
});
// OpenSeadragon WMTS plugin
var map = await OpenSeadragon.WMTS(viewer, {
url: 'http://maps.wien.gv.at/wmts/1.0.0/WMTSCapabilities.xml'
});
// Initialize Annotorious
var anno = OpenSeadragon.Annotorious(viewer);
// Add the map annotation plugin
Annotorious.MapAnnotation(anno, map);