al_unlock_bitmap(3alleg5)
β¨ 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 π
al_lock_bitmap(3alleg5)β the lock that this unlocks πal_lock_bitmap_region(3alleg5)β locking just a lil slice of it πal_lock_bitmap_blocked(3alleg5)β the blocked-flavour lock π§al_lock_bitmap_region_blocked(3alleg5)β blocked and regional, iconic π
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
- debian trixie: allegro5-doc 2:5.2.10.1+dfsg-1 Β· Zlib
- ubuntu questing: allegro5-doc 2:5.2.10.1+dfsg-1build1
- ubuntu resolute: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- ubuntu stonking: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms