al_map_rgb_f(3alleg5)

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

πŸ’– al_map_rgb_f β€” the Allegro 5 API page πŸ’–

okay bestie, so this is a page from the Allegro 5 manual (that's the 3alleg5 section, iykyk) and it's literally about making a colour out of float numbers. iconic. let's get into it ✨


🌈 SYNOPSIS 🌈

#include <allegro5/allegro.h>

ALLEGRO_COLOR al_map_rgb_f(float r, float g, float b)

πŸŽ€ DESCRIPTION πŸŽ€

so what does it do? it takes r, g, and b β€” which range from 0.0f-1.0f β€” and converts them into an ALLEGRO_COLOR(3alleg5), using 1.0f for alpha. that's it. that's the whole vibe. πŸ¦‹

lowkey the best part: this function can be called before Allegro is initialized. no setup era required, she just works. πŸ’…

πŸ’œ SEE ALSO πŸ’œ


okay that's the whole page, fr fr 🌸 this was brought to you by the Allegro reference manual, page al_map_rgb_f(3alleg5) β€” go forth and colour slay, bestie πŸ’–βœ¨πŸ‘‘

πŸ“¦ where this page comes from