al_unlock_bitmap(3alleg5)

πŸ“¦
version 5.2.11.3 Β· 4 versions
, in debian trixie, ubuntu questing, ubuntu resolute, ubuntu stonking

✨ al_unlock_bitmap ✨

okay bestie, so this one lives in the allegro5 manual (section 3alleg5, for the record) and it's the little sister function to al_lock_bitmap πŸ’– it's short, it's sweet, it's giving "closing the door behind you" energy. let's get into it πŸŽ€


🌸 NAME 🌸

al_unlock_bitmap β€” Allegro 5 API πŸ‘‘


πŸ¦‹ SYNOPSIS πŸ¦‹

#include <allegro5/allegro.h>

void al_unlock_bitmap(ALLEGRO_BITMAP *bitmap)

πŸ’… DESCRIPTION πŸ’…

So basically: you know how you locked a bitmap (or a region of a bitmap) earlier? yeah. This is how you unlock it. That's the whole vibe. πŸ”“βœ¨

And here's the part that actually matters, no cap: if the bitmap you're unlocking is a video bitmap, then the texture gets updated to match the system memory copy. Slay. Your changes actually make it to the GPU, bestie 🫢

one tiny caveat though πŸ‘€ that texture update happens unless it was locked read only. If you locked it read only, there's nothing to sync back, iykyk. So don't be surprised when nothing moves πŸ’€

πŸ‘‘ SEE ALSO πŸ‘‘


and that's the whole page fr fr πŸ’œ mwah, go unlock something.

this has been a lil transmission from the Allegro reference manual, section 3alleg5, brought to you by the al_unlock_bitmap(3alleg5) girlies πŸ’…βœ¨ bye bestie!!

πŸ“¦ where this page comes from