al_use_shader(3alleg5)

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

✨ al_use_shader ✨

ok so bestie, this one's from the Allegro 5 API β€” aka the Allegro reference manual, and we're talking about al_use_shader πŸ’… buckle up.


🌸 SYNOPSIS 🌸

#include <allegro5/allegro.h>

bool al_use_shader(ALLEGRO_SHADER *shader)

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so here's the tea β˜• β€” al_use_shader makes your shader the main character for all the drawing you do next on the current target bitmap. every subsequent drawing operation? yeah, that shader is running the show now. slay ✨

and if you wanna stop using any shader on the current target bitmap, you just pass NULL. that's it, no shader, back to normal vibes πŸŽ€

it returns true on success πŸ’– otherwise it returns false β€” like, for example, when the shader is incompatible with the target bitmap. that's the vibe check failing, bestie, no cap 😭


⭐ SINCE ⭐

5.1.6 β€” vintage but iconic πŸ‘‘


πŸ’œ SEE ALSO πŸ’œ


🫢 the whole friend group's here, go read all of them, iykyk

and that's the page, bestie β€” this little love letter to al_use_shader lives in the Allegro reference manual πŸ’– go off, and remember: pass NULL when you're done, don't leave your shaders hanging 🧚✨

πŸ“¦ where this page comes from