Skip to content

Conversation

lukemckinstry
Copy link
Contributor

@lukemckinstry lukemckinstry commented Sep 23, 2025

Description

There will be multiple ways to add Google2D data - explained in docs

  • IonImageryProvider.fromAssetId
    • Works exactly the same as all other assets hosted in ion. ion will have 5 Google Maps assets.
  • Google2DImageryProvider.fromIonAssetId
    • similar to IonImageyProvider.fromAssetId, but user can add params to create custom maps and overlays beyond the 5 available in ion. Data still streams via ion.
  • Google2DImageryProvider.fromUrl
    • For users who opt not to stream via ion, sets up session and steams tiles directly from Google api
  • Google2DImageryProvider constructor -
    • docs have note This object is normally not instantiated directly, use Google2DImageryProvider.fromIon or Google2DImageryProvider.fromUrl.

ToDo

DO NOT MERGE until complete

Issue number and link

Testing plan

Sandcastles (to publish in prod)

To view the sandcastles, add the key to your Ion Staging account.

Test all ways to add Google 2D data

  • IonImageryProvider.fromAssetId() - sandcastle 1&2
  • Google2DImageryProvider.fromIonAssetId (with and params to create maps, overlays and custom styles on a roadmap)- sandcastle 3
  • Google2DImageryProvider.fromUrl
    • In sandcastles replace Google2DImageryPrivider fromIon with fromUrl
    • add Google api key
Cesium.Google2DImageryProvider.fromUrl({
  key: apiKey,
  mapType: "terrain",
}),
  • test token refresh
//add to bottom of sandcastle using IonImageryProvider.fromAssetId
setTimeout(() => {
  google._imageryProvider._imageryProvider._imageryProvider._resource.setQueryParameters({key: "invalid-key"})
},3000)

//add to bottom of sandcastle using Google2DImageryProvider.fromIon
setTimeout(() => {
  google._imageryProvider._imageryProvider._resource.setQueryParameters({key: "derp"})
},3000)
  • Check attribution - satellite map has most attribution

Author checklist

  • I have submitted a Contributor License Agreement
  • I have added my name to CONTRIBUTORS.md
  • I have updated CHANGES.md with a short summary of my change
  • I have added or updated unit tests to ensure consistent code coverage
  • I have updated the inline documentation, and included code examples where relevant
  • I have performed a self-review of my code

Copy link

Thank you for the pull request, @lukemckinstry!

✅ We can confirm we have a CLA on file for you.

Copy link
Contributor

@ggetz ggetz left a comment

Choose a reason for hiding this comment

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

Looking good on an initial pass @lukemckinstry! Just a few comments to consider as you continue to add updates.

@lukemckinstry lukemckinstry force-pushed the google-azure-2d-imagery branch from e4bb5a0 to 7080a35 Compare September 26, 2025 01:23
@lukemckinstry
Copy link
Contributor Author

@ggetz thanks for the PR feedback. I addressed all the comments from the latest review.

@ggetz
Copy link
Contributor

ggetz commented Sep 30, 2025

@lukemckinstry Pushed up a fix/refactor to how we're handling IonResources and credits, as discussed. Please let me know if there are any questions.

@lukemckinstry

This comment was marked as resolved.

@ggetz
Copy link
Contributor

ggetz commented Oct 1, 2025

Looks like changing the attribution list on the fly is causing problems for our credits popup.

Ah, that's no good. However, and correct me if I'm mistaken, this issue is not unique to the Google imagery provider–which is now using the more standard method of attribution.

Non-ideal for sure, but I don't think it need to hold up this PR. @lukemckinstry Could you open a new issue for the data attribution popup, assuming there is not already one open?

@lukemckinstry lukemckinstry added this pull request to the merge queue Oct 1, 2025
Merged via the queue into main with commit 0e35728 Oct 1, 2025
12 of 13 checks passed
@lukemckinstry lukemckinstry deleted the google-azure-2d-imagery branch October 1, 2025 16:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants