natiny_clip_destroy
void natiny_clip_destroy(NatinyClip clip);
Frees a clip's decoded audio.
Parameters
| Name | Type | Description |
|---|---|---|
clip |
NatinyClip |
Clip handle |
Example
natiny_clip_destroy(clip);
Notes
- Do not use the clip handle after destroy.
- Sources still pointing at the clip play nothing. They are not destroyed and
stay usable: give one another clip with
natiny_audio_source_set_clip. - Clips are not reference counted. Destroying one while sources play it is safe - the samples are held until the mixer has been seen to let go of them - but it silences those sources.
natiny_audio_shutdownleaves clips alone;natiny_backend_shutdowndestroys them along with the rest of the engine state.- Invalid and already destroyed handles are ignored.