SDL_Metal_DestroyView(3)

πŸ’… SDL_Metal_DestroyView πŸ’…

okay bestie, welcome to the SDL3 functions corner of the man pages, where today's main character is SDL_Metal_DestroyView β€” the lil cleanup queen who takes your Metal view out behind the shed (gently!!) and says goodbye πŸ’–


✨ NAME ✨

SDL_Metal_DestroyView β€” destroys an SDL_MetalView object that already exists. like, it's already here, and now it's not. closure, literally πŸ¦‹


✨ SYNOPSIS ✨

#include <SDL3/SDL_metal.h>

void SDL_Metal_DestroyView(SDL_MetalView view);

✨ DESCRIPTION ✨

so here's the tea πŸ«– β€” you should call this before SDL_DestroyWindow, but only in the specific situation where you called SDL_Metal_CreateView after SDL_CreateWindow. that ordering matters, bestie. it's giving "clean up your own mess in the right order or the vibes will be off" 😭


✨ FUNCTION PARAMETERS ✨

  • view β€” the SDL_MetalView object. the one you're sending off into the sunset πŸŒ…

✨ THREAD SAFETY ✨

⚠️ main thread ONLY. no cap. do not try to be cute and call this from a worker thread, it will not slay, it will just break things πŸ’€

✨ AVAILABILITY ✨

this one's been around since SDL 3.2.0 β€” so if you're on anything older, it's not a vibe check you're passing, it literally does not exist for you πŸ™ˆ


✨ SEE ALSO ✨


and that's the whole page, periodt πŸ‘‘

Simple Directmedia Layer wrote this one, it's from SDL 3.4.18, and the date on the original footer is baked right into that same line. mwah, take care of your Metal views and they'll take care of you πŸ’œβœ¨πŸŽ€

πŸ“¦ where this page comes from