natiny.surface.destroy
natiny.surface.destroy(surf)
Destroys a surface and releases its GPU resources.
Parameters
| Name | Type | Description |
|---|---|---|
surf |
number |
Surface handle from natiny.surface.create |
Example
local rt = natiny.surface.create(512, 512)
natiny.surface.destroy(rt)
Notes
- Do not use the surface handle after destroy.