Class DataProviderAsset
- Namespace
- Pinwheel.Vista.RealWorldData
- Assembly
- Pinwheel.Vista.RealWorldData.Runtime.dll
Base asset for real-world data providers that download, cache, and expose height or color maps for Vista workflows.
public abstract class DataProviderAsset : ScriptableObject
- Inheritance
-
ObjectScriptableObjectDataProviderAsset
- Derived
- Inherited Members
-
ScriptableObject.SetDirty()ScriptableObject.CreateInstance<T>()Object.GetInstanceID()Object.GetHashCode()Object.Instantiate(Object, Vector3, Quaternion)Object.Instantiate(Object, Vector3, Quaternion, Transform)Object.Instantiate(Object)Object.Instantiate(Object, Transform)Object.Instantiate<T>(T)Object.Instantiate<T>(T, Vector3, Quaternion)Object.Instantiate<T>(T, Vector3, Quaternion, Transform)Object.Instantiate<T>(T, Transform)Object.Destroy(Object)Object.DestroyImmediate(Object)Object.DontDestroyOnLoad(Object)Object.DestroyObject(Object)Object.FindObjectsOfType<T>()Object.FindObjectsByType<T>(FindObjectsSortMode)Object.FindObjectsByType<T>(FindObjectsInactive, FindObjectsSortMode)Object.FindObjectOfType<T>()Object.FindFirstObjectByType<T>()Object.FindAnyObjectByType<T>()Object.FindFirstObjectByType<T>(FindObjectsInactive)Object.FindAnyObjectByType<T>(FindObjectsInactive)Object.ToString()Object.nameObject.hideFlags
Remarks
Implementations usually forward the actual download work to an IRwdProvider, while this base class keeps the selected geographic bounds, stores the downloaded raw texture data in serialized fields, and lazily rebuilds runtime textures for preview or graph input.
Properties
- colorMap
Lazily rebuilds and returns the runtime color texture from the serialized color-map data buffer.
- dataRequest
Most recent request launched by this asset.
- heightMap
Lazily rebuilds and returns the runtime height texture from the serialized height-map data buffer.
- longLat
Geographic area, in longitude and latitude, used when this asset requests data.
- maxHeight
Highest terrain height, in meters, that the provider considers meaningful for the downloaded height range.
- minHeight
Lowest terrain height, in meters, that the provider considers meaningful for the downloaded height range.
- provider
Provider implementation responsible for downloading the data exposed by this asset.
Methods
- RequestAndSaveAll()
Requests every data type supported by provider and stores the returned buffers in this asset.
- RequestAndSaveColorMap()
Requests a color map for longLat and saves it into this asset if the returned data is valid.
- RequestAndSaveHeightMap()
Requests a height map for longLat and saves it into this asset if the returned data is valid.
- RequestColorMap(GeoRect)
Starts a color-map request for the specified geographic area.
- RequestHeightMap(GeoRect)
Starts a height-map request for the specified geographic area.
- Reset()
Restores the default geographic area used by this asset.
- SetColorMap(Color32[], Vector2Int)
Replaces the stored color-map buffer and invalidates the lazily built runtime texture.
- SetHeightMap(float[], Vector2Int)
Replaces the stored height-map buffer and invalidates the lazily built runtime texture.