Skip to content

Commit

Permalink
Merge pull request #8352 from AnalyticalGraphicsInc/fix-wmts-sandcastle
Browse files Browse the repository at this point in the history
Fix broken URL in WMTS + time Sandcastle
  • Loading branch information
lilleyse authored Feb 3, 2020
2 parents d7bb3be + 1d38b66 commit bc8b44e
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
18 changes: 11 additions & 7 deletions Apps/Sandcastle/gallery/Web Map Tile Service with Time.html
Original file line number Diff line number Diff line change
Expand Up @@ -47,20 +47,22 @@
dataCallback: dataCallback
});

// Add a WMTS imagery layer
// Add a WMTS imagery layer.
// This comes from NASA's GIBS API.
// See https://wiki.earthdata.nasa.gov/display/GIBS/GIBS+API+for+Developers#GIBSAPIforDevelopers-OGCWebMapService(WMS)
var provider = new Cesium.WebMapTileServiceImageryProvider({
url : 'https://gibs.earthdata.nasa.gov/wmts/epsg4326/best/AMSR2_Snow_Water_Equivalent/default/{Time}/{TileMatrixSet}/{TileMatrix}/{TileRow}/{TileCol}.png',
layer : 'AMSR2_Snow_Water_Equivalent',
url : 'https://gibs.earthdata.nasa.gov/wmts/epsg4326/best/MODIS_Terra_CorrectedReflectance_TrueColor/default/{Time}/{TileMatrixSet}/{TileMatrix}/{TileRow}/{TileCol}.jpg',
layer : 'MODIS_Terra_CorrectedReflectance_TrueColor',
style : 'default',
tileMatrixSetID : '2km',
tileMatrixSetID : '250m',
maximumLevel : 5,
format : 'image/png',
format : 'image/jpeg',
clock: viewer.clock,
times: times,
credit : 'NASA Global Imagery Browse Services for EOSDIS'
});
var imageryLayers = viewer.imageryLayers;
imageryLayers.addImageryProvider(provider);
var layer = imageryLayers.addImageryProvider(provider);
provider.readyPromise
.then(function() {
var start = Cesium.JulianDate.fromIso8601('2015-07-30');
Expand All @@ -73,7 +75,9 @@
clock.stopTime = stop;
clock.currentTime = start;
clock.clockRange = Cesium.ClockRange.LOOP_STOP;
clock.multiplier = 86400;
clock.multiplier = 7200;
// Make the weather layer semi-transparent to see the underlying geography.
layer.alpha = 0.5;
});
//Sandcastle_End
Sandcastle.finishedLoading();
Expand Down
Binary file modified Apps/Sandcastle/gallery/Web Map Tile Service with Time.jpg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit bc8b44e

Please sign in to comment.