There may be times when you want to display an image for which you only have the Texture2D object. In this case, you can add it to the cache with a given name and then access it in PowerUI using cache://theNameYouUsed. The most useful method for this is PowerUI.ImageCache.Add.
Static Public Member Functions | |
static void | Add (string address, Texture2D image) |
Adds an image to the cache. More... | |
static Texture2D | Get (string address) |
Gets a named image from the cache. More... | |
static void | Remove (string address) |
Removes an image from the cache. More... | |
static void | Clear () |
Clears the cache of all its contents. More... | |
Static Private Attributes | |
static Dictionary< string, Texture2D > | Lookup =new Dictionary<string,Texture2D>() |
The set of all cached textures. More... | |
|
inlinestatic |
Adds an image to the cache.
address | The name to use to find your image. |
image | The image to store in the cache. |
|
inlinestatic |
Clears the cache of all its contents.
|
inlinestatic |
Gets a named image from the cache.
address | The name of the image to find. |
|
inlinestatic |
Removes an image from the cache.
address | The name of the image to remove. |
|
staticprivate |
The set of all cached textures.