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

Change ol.TileCoord to Array.<number> #2539

Merged
merged 1 commit into from Aug 18, 2014
Merged

Change ol.TileCoord to Array.<number> #2539

merged 1 commit into from Aug 18, 2014

Conversation

elemoine
Copy link
Member

This PR changes the ol.TileCoord type to an array of three numbers: [z, x, y]. This is as discussed in #2514.

I did not test every example. I would be good that someone else could also test some of the examples. Thanks.

Closes #2514.

@@ -161,16 +161,16 @@ ol.source.WMTS = function(options) {
ol.extent.getWidth(extent) /
ol.extent.getWidth(tileExtent));
x = goog.math.modulo(x, numCols);
tmpTileCoord.z = tileCoord.z;
tmpTileCoord.z = tileCoord[0];
Copy link
Member

Choose a reason for hiding this comment

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

should be:

tmpTileCoord[0] = tileCoord[0];
tmpTileCoord[1] = x;
tmpTileCoord[2] = tileCoord[2];

Copy link
Member Author

Choose a reason for hiding this comment

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

Good catch @fredj! Now fixed.

@fredj
Copy link
Member

fredj commented Aug 18, 2014

Looks good to me, thanks Eric

elemoine pushed a commit that referenced this pull request Aug 18, 2014
Change ol.TileCoord to Array.<number>
@elemoine elemoine merged commit 0779b4e into openlayers:master Aug 18, 2014
@elemoine elemoine deleted the tilecoord branch August 18, 2014 08:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace ol.TileCoord with simple Object (or with Array.<number>)
2 participants