gui_get_screen(3)

πŸ“¦ version 4.4.3.1, in fedora 43, fedora 44

πŸ’– gui_get_screen(3) πŸ’–

okay bestie, welcome to the Allegro manual β€” yes THE Allegro game programming library β€” and today's main character is a lil function called gui_get_screen. it's short, it's sweet, it's giving "i just tell you where the pixels are going" πŸŽ€


✨ NAME ✨

gui_get_screen β€” returns the bitmap surface the GUI routines draw to. πŸ’… (also: it lives in the Allegro game programming library, if that wasn't obvious from the neon sign above πŸ¦‹)


🌸 SYNOPSIS 🌸

#include <allegro.h>

BITMAP *gui_get_screen(void);

no arguments, no drama, just vibes and a return value 🫢


πŸ’œ DESCRIPTION πŸ’œ

okay so here's the tea: this function hands you back the current bitmap surface that the GUI routines are gonna use for drawing. that's it. that's the whole job. iconic behavior, honestly πŸ‘‘

and like β€” two things you need to know, no cap:

  • if you previously called gui_set_screen(NULL), this function will return screen. so yeah, it's got your back and falls back to the default. 🌈
  • it will never return NULL. never ever. not once. so don't go doing a if (result == NULL) vibe check on it, because it's not happening, bestie 😭✨

πŸ‘‘ SEE ALSO πŸ‘‘

  • gui_set_screen(3) β€” the one that actually sets the thing. the duo. the ship. iykyk πŸ’–

and that's the whole page, gorgeous. this little legend comes to you courtesy of Allegro, and it's version 4.4.3 β€” so like, respect the vintage, it ate and left no crumbs πŸ’…βœ¨ mwah, go draw something pretty πŸŽ€πŸ¦‹

πŸ“¦ where this page comes from