1 (edited by mikejm 2023-06-07 05:52:23)

Topic: Manually getting Bing/Google Maps Texture2D results from coordinates?

I would like to use Online Maps programmatically with UI Toolkit. I want to be able to specify a given location (GPS) and zoom level in code with an API key and return a Texture2D or JPG or array of Texture2D or JPG's I can use to display on my own UI Toolkit elements (as VisualElement backgrounds) with Bing ideally or Google perhaps.

Can you provide me with any thoughts or basic start on how to format such a scripted query and what it will return in terms of Texture2D or JPG results?

If I can get any number of tiles of JPG or Texture2D data from a given query, I can figure out how to display it according.

Thanks for any help. It's a great system and I appreciate it.

Re: Manually getting Bing/Google Maps Texture2D results from coordinates?

Hi.

To display a map on a UI Toolkit (or any other source that is not supported out of the box), you need to implement your own Control by inheriting OnlineMapsControlBase, OnlineMapsControlBase2D (in your case) or OnlineMapsControlBase3D.

This is mainly needed to convert the coordinates into a position on the display source.
Look at the sources of existing Controls to see how to do this.

Kind Regards,
Infinity Code Team.

Boost your productivity a lot and immediately using Ultimate Editor Enhancer. Trial and non-commerce versions available.