al_draw_tinte..._bitmap_region(3alleg5)
π NAME π
al_draw_tinted_scaled_rotated_bitmap_region β Allegro 5 API, bestie. The name is a whole mouthful fr fr, so we're calling it "the region one" from here on, iykyk.
β¨ SYNOPSIS β¨
#include <allegro5/allegro.h>
void al_draw_tinted_scaled_rotated_bitmap_region(ALLEGRO_BITMAP *bitmap,
float sx, float sy, float sw, float sh,
ALLEGRO_COLOR tint,
float cx, float cy, float dx, float dy, float xscale, float yscale,
float angle, int flags)
πΈ DESCRIPTION πΈ
Okay so it's literally al_draw_tinted_scaled_rotated_bitmap(3alleg5) β same energy, same slay β except you get to pick a specific little area inside the bitmap to actually draw. Crop moment. π
And if you're sitting there like "can't I just do this another way", yes babes, you can β you can get the exact same effect with a sub bitmap:
al_draw_tinted_scaled_rotated_bitmap(bitmap, sx, sy, sw, sh, tint,
cx, cy, dx, dy, xscale, yscale, angle, flags);
/* This draws the same: */
sub_bitmap = al_create_sub_bitmap(bitmap, sx, sy, sw, sh);
al_draw_tinted_scaled_rotated_bitmap(sub_bitmap, tint, cx, cy,
dx, dy, xscale, yscale, angle, flags);
Same result, two roads, both iconic. π
Heads up though β go read al_draw_bitmap(3alleg5) for the note about restrictions on which bitmaps can be drawn where. Not every bitmap gets to show up everywhere, and that's just the rules, no cap. π«Ά
π¦ SINCE π¦
5.0.6, 5.1.0 β so she's been around a minute. Vintage, honestly. π
π SEE ALSO π
al_draw_tinted_bitmap(3alleg5)β go give her a read too, she's the related one β¨
And that's the whole page, bestie!! This was the Allegro reference manual talking about al_draw_tinte..._bitmap_region(3alleg5), and honestly? She ate. Go draw something cute with a sub-region of a bitmap and think of me. Byeee ππ§π
π¦ where this page comes from
- debian trixie: allegro5-doc 2:5.2.10.1+dfsg-1 Β· Zlib
- ubuntu questing: allegro5-doc 2:5.2.10.1+dfsg-1build1
- ubuntu resolute: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- ubuntu stonking: allegro5-doc 2:5.2.11.3+dfsg-1 Β· Zlib
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms