AL_REGISTER_BITMAP_LOADER_F(3)

πŸ“¦
version 5.2.11.3 Β· 3 versions
, in arch rolling

✨ al_register_bitmap_loader_f(3) ✨

okay so bestie, welcome to the Allegro 5 API reference manual πŸ’– this one's a little function with main character energy β€” it's all about telling Allegro who's in charge of loading your bitmap files πŸŽ€


✨ SYNOPSIS ✨

#include <allegro5/allegro.h>

bool al_register_bitmap_loader_f(const char *extension,
   ALLEGRO_BITMAP *(*fs_loader)(ALLEGRO_FILE *fp, int flags))

like, look at that signature. she's beautiful. πŸ¦‹


🌸 DESCRIPTION 🌸

okay so here's the tea β˜• β€” this function registers a handler for al_load_bitmap_f(3). The function you pass in is the one that'll be used to handle loading bitmap files with the extension you give it. no cap, that's literally the whole vibe ✨

The extension should include the leading dot (.) character. and the way it gets matched? case-insensitively πŸ’… so don't stress about caps.

The fs_loader argument may be NULL to unregister an entry β€” yes queen, you can yeet a handler out of existence πŸ™ˆ

It returns true on success, false on error. And heads up: it returns false if you're unregistering an entry that doesn't exist 😭 (iykyk, vibe check failed).


πŸ¦‹ SEE ALSO πŸ¦‹


Allegro reference manual πŸ’œ al_registe...ap_loader_f(3) β€” mwah, that's the whole page, slay πŸ’…βœ¨πŸŽ€

πŸ“¦ where this page comes from
  • arch rolling: allegro 5.2.11.3-2 Β· Zlib AND BSD-3-Clause AND OFL-1.1 AND LicenseRef-Custom
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms