al_set_sha...oat_vector(3)
π al_set_shader_float_vector β Allegro 5 API, bestie β¨
Okay so this is a page straight outta the Allegro 5 API manual (the Allegro reference manual girlies stay winning π«Ά), and it's genuinely so simple you're gonna eat this up.
πΈ NAME πΈ
al_set_shader_float_vector β the Allegro 5 API function that sets a float vector in a shader, no cap π
β¨ SYNOPSIS β¨
Like, here's the exact vibe:
#include <allegro5/allegro.h>
bool al_set_shader_float_vector(const char *name,
int num_components, const float *f, int num_elems)
That return type? bool. That's it, that's the whole signature, she's iconic π
π¦ DESCRIPTION π¦
So basically this function is literally the same as al_set_shader_int_vector(3) β like, same energy, same everything β except all the values are float instead of int. That's the whole plot twist. Floating point glow-up fr fr πβ¨
If you already know how al_set_shader_int_vector(3) works, congrats, you already know this one. Group chat's already caught up π«Ά
π SINCE π
5.1.0 β she's been here since 5.1.0, a true veteran π
π SEE ALSO π
al_set_shader_int_vector(3)β the int version, her sibling πal_use_shader(3)β the one you probably need to call too, iykyk π₯
Quick vibe check: this page is short and sweet, so don't overthink it β just remember: floats, not ints, and same behaviour as the int vector function. Periodt. π
Sign-off time bestie πβ¨ This little page lives in the Allegro reference manual β source of all this Allegro 5 API goodness β so go forth, set those float vectors, and 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