Loads, caches, and destroys GPU images.
Lua full name: lysa.ImageManager
|
| Image | load (path: string) |
| | Loads an image from the given virtual path and uploads it to the GPU. More...
|
| |
| nil | save (img: Image, path: string) |
| | Saves an image to disk at the given virtual path. More...
|
| |
| Image | get (id: integer) |
| | Returns the image with the given id. More...
|
| |
| Image | get (name: string) |
| | Returns the image with the given name; raises an exception if not found. More...
|
| |
| boolean | contains (name: string) |
| | Returns true if an image with the given name exists. More...
|
| |
| nil | destroy (id: integer) |
| | Destroys the image with the given id and releases its GPU memory. More...
|
| |
| nil | destroy (img: Image) |
| | Destroys the given image and releases its GPU memory. More...
|
| |
| nil | destroy (ids: integer[]) |
| | Destroys all images in the list and releases their GPU memory. More...
|
| |
|
| Image | blank_image |
| | 1×1 white RGBA image usable as a no-texture placeholder. (read-only)
|
| |
| Image | blank_cube_map |
| | 1×1 white cube-map usable as a no-texture placeholder. (read-only)
|
| |
| table<integer, | images |
| | lysa.Image> All loaded images keyed by id. (read-only)
|
| |