Skip to content

Commit

Permalink
Adds option to view untiled data.
Browse files Browse the repository at this point in the history
  • Loading branch information
neomorphic committed Jun 1, 2016
1 parent 548e200 commit 9576122
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 4 deletions.
12 changes: 10 additions & 2 deletions js/components/TileMapArea.react.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ var TileMapArea = React.createClass({
tileSize = tileData.Extended.Levels[0].TileSize[0];
}

viewer = new TileViewer({
var viewerOpts = {
id: 'viewer',
maxZoom: maxLevel,
tileSource: url + '/api/node/' + uuid + '/' + tileSource + '/tile/xy/{zoom}/{x}_{y}_{z}',
Expand All @@ -129,7 +129,15 @@ var TileMapArea = React.createClass({
x_mid: dx,
y_mid: dy,
segTileSize: 256
});
};

if (!dataIsTiled) {
viewerOpts.rawImages = true;
viewerOpts.tileSource = url + '/api/node/' + uuid + '/' + tileSource + "/raw/xy/{tile}_{tile}/{x}_{y}_{z}";
}

viewer = new TileViewer(viewerOpts);


window.viewer = viewer;

Expand Down
Loading

0 comments on commit 9576122

Please sign in to comment.