Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement TileMapServiceImageryProvider in terms of UrlTemplateImageryProvider #3150

Closed
wants to merge 40 commits into from
Closed
Show file tree
Hide file tree
Changes from 39 commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
14b8741
implemented TMS in terms of UrlTemplateImageryProvider, changed TMSSp…
sen-lu Oct 23, 2015
680b0c8
construct UrlTemplateImageryProvider from local variables
sen-lu Oct 30, 2015
1c80bdd
moved TMSSpec changes to a separate branch (tmsSpec)
sen-lu Oct 30, 2015
2dff53a
rebased onto master
sen-lu Oct 30, 2015
4f78349
Merge branch 'tileMapServiceImageryProvider' of https://github.com/ti…
sen-lu Oct 30, 2015
744972b
Merge remote-tracking branch 'origin/master' into tileMapServiceImage…
pjcozzi Oct 30, 2015
49cba9c
implemented TMS in terms of UrlTemplateImageryProvider, changed TMSSp…
sen-lu Oct 23, 2015
a05c019
construct UrlTemplateImageryProvider from local variables
sen-lu Oct 30, 2015
6833a58
moved TMSSpec changes to a separate branch (tmsSpec)
sen-lu Oct 30, 2015
84b6f0a
rebased onto master
sen-lu Oct 30, 2015
d22bcfc
merged deferredUrlTemplate and implemented TMS accordingly
sen-lu Nov 11, 2015
254eb51
merged remote
sen-lu Nov 11, 2015
7c6e661
added hasReadyPromise to UrlTemplateImageryProvider
sen-lu Nov 16, 2015
9ef0bed
made minor changes to TMSSpec
sen-lu Nov 16, 2015
52c5e39
merged in master
sen-lu Nov 16, 2015
c29db23
fixed build failures
sen-lu Nov 16, 2015
bbb1361
added documentation for hasReadyPromise
sen-lu Nov 16, 2015
2fac84a
removed url and readyPromise property overrides
sen-lu Nov 16, 2015
667eac9
merged in master
sen-lu Nov 21, 2015
10bfa76
added createTMS spec
sen-lu Nov 21, 2015
cd6c099
updated project-wide TMS references to createTMS
sen-lu Nov 24, 2015
88e852b
deprecated TMS, updates CHANGES.md
sen-lu Nov 24, 2015
a37e301
reverted TMSSpec
sen-lu Nov 24, 2015
94eedda
tweaked createTMSSpec
sen-lu Nov 24, 2015
7d55744
Reorder require statements
pjcozzi Nov 24, 2015
a9f9b61
Fix links
pjcozzi Nov 24, 2015
2f77bf4
Fix formatting
pjcozzi Nov 24, 2015
e3766fb
Update doc
pjcozzi Nov 24, 2015
0f10a57
set member values in constructor to undefined
sen-lu Nov 25, 2015
fad9cbd
implemented UrlTemplate promise to options
sen-lu Nov 25, 2015
a441be5
urlTemplate promise and errorEvent handling
sen-lu Nov 25, 2015
9806476
fixed reference
sen-lu Dec 2, 2015
59bbb38
fixed UrlTemplateImageryProvider promise bug
sen-lu Dec 2, 2015
463f993
add tests for all DeveloperExceptions
sen-lu Dec 2, 2015
1143c78
merge in master
sen-lu Dec 2, 2015
dfb0512
tweaks
sen-lu Dec 10, 2015
c69ecb4
merged master
sen-lu Dec 10, 2015
4b0c00d
changes.md
sen-lu Dec 10, 2015
288852a
merged master
sen-lu Dec 16, 2015
52f2c62
syntax
sen-lu Dec 16, 2015
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Apps/CesiumViewer/CesiumViewer.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ define([
'Cesium/DataSources/CzmlDataSource',
'Cesium/DataSources/GeoJsonDataSource',
'Cesium/DataSources/KmlDataSource',
'Cesium/Scene/TileMapServiceImageryProvider',
'Cesium/Scene/createTileMapServiceImageryProvider',
'Cesium/Widgets/Viewer/Viewer',
'Cesium/Widgets/Viewer/viewerCesiumInspectorMixin',
'Cesium/Widgets/Viewer/viewerDragDropMixin',
Expand All @@ -26,7 +26,7 @@ define([
CzmlDataSource,
GeoJsonDataSource,
KmlDataSource,
TileMapServiceImageryProvider,
createTileMapServiceImageryProvider,
Viewer,
viewerCesiumInspectorMixin,
viewerDragDropMixin) {
Expand All @@ -47,7 +47,7 @@ define([

var imageryProvider;
if (endUserOptions.tmsImageryUrl) {
imageryProvider = new TileMapServiceImageryProvider({
imageryProvider = createTileMapServiceImageryProvider({
url : endUserOptions.tmsImageryUrl
});
}
Expand Down
4 changes: 2 additions & 2 deletions Apps/Sandcastle/gallery/Imagery Layers Manipulation.html
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@
}));
addBaseLayerOption(
'Natural Earth II (local)',
new Cesium.TileMapServiceImageryProvider({
Cesium.createTileMapServiceImageryProvider({
url : require.toUrl('Assets/Textures/NaturalEarthII')
}));
addBaseLayerOption(
Expand Down Expand Up @@ -181,7 +181,7 @@
}));
addAdditionalLayerOption(
'TileMapService Image',
new Cesium.TileMapServiceImageryProvider({
Cesium.createTileMapServiceImageryProvider({
url : '../images/cesium_maptiler/Cesium_Logo_Color'
}),
0.2);
Expand Down
2 changes: 1 addition & 1 deletion Apps/Sandcastle/gallery/Imagery Layers.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
});

var layers = viewer.imageryLayers;
var blackMarble = layers.addImageryProvider(new Cesium.TileMapServiceImageryProvider({
var blackMarble = layers.addImageryProvider(Cesium.createTileMapServiceImageryProvider({
url : '//cesiumjs.org/blackmarble',
maximumLevel : 8,
credit : 'Black Marble imagery courtesy NASA Earth Observatory'
Expand Down
4 changes: 4 additions & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,15 @@ Change Log
* Removed `HeightmapTessellator` from the public API. It is now private and subject to change without notice.
* Removed `TerrainMesh` from the public API. It is now private and subject to change without notice.
* Removed `jsonp`. Use `loadJsonp` instead.
* Deprecated
* Deprecated `TileMapServiceImageryProvider`. It will be removed in 1.18. Use `createTileMapServiceImageryProvider` instead.
* Refactored `UrlTemplateImageryProvider.reinitialize` to accept a promise to `options`.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's change this to:

`UrlTemplateImageryProvider` and `UrlTemplateImageryProvider.reinitialize` now accept a promise to an `options` object in addition to taking the object directly.

* Reduced the amount of both GPU and CPU memory used by terrain. The CPU memory was reduced by up to 40%.
* `CorridorGeometry` and `PolylineVolumeGeometry` render short segments [#3293](https://github.com/AnalyticalGraphicsInc/cesium/issues/3293)
* `Rectangle.fromCartographicArray` finds the smallest rectangle regardess of whether or not it crosses the international date line. [#3227](https://github.com/AnalyticalGraphicsInc/cesium/issues/3227)
* Bug fix for `CorridorGeometry` with nearly colinear points [#3320](https://github.com/AnalyticalGraphicsInc/cesium/issues/3320)


Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please remove this whitespace.

### 1.16 - 2015-12-01

* Deprecated
Expand Down
2 changes: 1 addition & 1 deletion Source/Core/CesiumTerrainProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ define([
*
* // Terrain geometry near the surface of the globe is difficult to view when using NaturalEarthII imagery,
* // unless the TerrainProvider provides additional lighting information to shade the terrain (as shown above).
* var imageryProvider = new Cesium.TileMapServiceImageryProvider({
* var imageryProvider = Cesium.createTileMapServiceImageryProvider({
* url : 'http://localhost:8080/Source/Assets/Textures/NaturalEarthII',
* fileExtension : 'jpg'
* });
Expand Down
2 changes: 1 addition & 1 deletion Source/Scene/ArcGisMapServerImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ define([
* @see GoogleEarthImageryProvider
* @see createOpenStreetMapImageryProvider
* @see SingleTileImageryProvider
* @see TileMapServiceImageryProvider
* @see createTileMapServiceImageryProvider
* @see WebMapServiceImageryProvider
* @see WebMapTileServiceImageryProvider
* @see UrlTemplateImageryProvider
Expand Down
2 changes: 1 addition & 1 deletion Source/Scene/BingMapsImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ define([
* @see GoogleEarthImageryProvider
* @see createOpenStreetMapImageryProvider
* @see SingleTileImageryProvider
* @see TileMapServiceImageryProvider
* @see createTileMapServiceImageryProvider
* @see WebMapServiceImageryProvider
* @see WebMapTileServiceImageryProvider
* @see UrlTemplateImageryProvider
Expand Down
3 changes: 1 addition & 2 deletions Source/Scene/GoogleEarthImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ define([
* @see BingMapsImageryProvider
* @see createOpenStreetMapImageryProvider
* @see SingleTileImageryProvider
* @see TileMapServiceImageryProvider
* @see createTileMapServiceImageryProvider
* @see WebMapServiceImageryProvider
* @see WebMapTileServiceImageryProvider
* @see UrlTemplateImageryProvider
Expand Down Expand Up @@ -591,4 +591,3 @@ define([

return GoogleEarthImageryProvider;
});

3 changes: 2 additions & 1 deletion Source/Scene/ImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,8 @@ define([
* include an alpha channel. If this property is false, an alpha channel, if present, will
* be ignored. If this property is true, any images without an alpha channel will be treated
* as if their alpha is 1.0 everywhere. When this property is false, memory usage
* and texture upload time are reduced.
* and texture upload time are reduced. This function should
* not be called before {@link ImageryProvider#ready} returns true.
* @memberof ImageryProvider.prototype
* @type {Boolean}
* @readonly
Expand Down
4 changes: 2 additions & 2 deletions Source/Scene/OpenStreetMapImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ define([
* @see BingMapsImageryProvider
* @see GoogleEarthImageryProvider
* @see SingleTileImageryProvider
* @see TileMapServiceImageryProvider
* @see createTileMapServiceImageryProvider
* @see WebMapServiceImageryProvider
* @see WebMapTileServiceImageryProvider
* @see UrlTemplateImageryProvider
Expand All @@ -64,7 +64,7 @@ define([
* var osm = new Cesium.OpenStreetMapImageryProvider({
* url : '//a.tile.openstreetmap.org/'
* });
*
*
* @deprecated
*/
function OpenStreetMapImageryProvider(options) {
Expand Down
2 changes: 1 addition & 1 deletion Source/Scene/SingleTileImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ define([
* @see BingMapsImageryProvider
* @see GoogleEarthImageryProvider
* @see createOpenStreetMapImageryProvider
* @see TileMapServiceImageryProvider
* @see createTileMapServiceImageryProvider
* @see WebMapServiceImageryProvider
* @see WebMapTileServiceImageryProvider
* @see UrlTemplateImageryProvider
Expand Down
10 changes: 8 additions & 2 deletions Source/Scene/TileMapServiceImageryProvider.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ define([
'../Core/defaultValue',
'../Core/defined',
'../Core/defineProperties',
'../Core/deprecationWarning',
'../Core/DeveloperError',
'../Core/Event',
'../Core/GeographicTilingScheme',
Expand All @@ -24,6 +25,7 @@ define([
defaultValue,
defined,
defineProperties,
deprecationWarning,
DeveloperError,
Event,
GeographicTilingScheme,
Expand All @@ -34,10 +36,13 @@ define([
TileProviderError,
WebMercatorTilingScheme,
when,
ImageryProvider) {
ImageryProvider
) {
"use strict";

/**
* @deprecated
*
* Provides tiled imagery as generated by {@link http://www.maptiler.org/'>MapTiler</a> / <a href='http://www.klokan.cz/projects/gdal2tiles/|GDDAL2Tiles} etc.
*
* @alias TileMapServiceImageryProvider
Expand Down Expand Up @@ -88,7 +93,8 @@ define([
* Cesium.Math.toRadians(40.0))
* });
*/
function TileMapServiceImageryProvider(options) {
function TileMapServiceImageryProvider(options) {
deprecationWarning('TileMapServiceImageryProvider', 'Scene/TileMapServiceImageryProvider is deprecated. Use Scene/createTileMapServiceImageryProvider instead.');
options = defaultValue(options, {});

//>>includeStart('debug', pragmas.debug);
Expand Down
Loading