al_draw_rounded_rectangle(3alleg5)

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

✨ NAME ✨

okay so this is al_draw_rounded_rectangle β€” it's part of the Allegro 5 API bestie, and it literally draws you a rounded rectangle outline πŸ’–


🌸 SYNOPSIS 🌸

#include <allegro5/allegro_primitives.h>

void al_draw_rounded_rectangle(float x1, float y1, float x2, float y2,
   float rx, float ry, ALLEGRO_COLOR color, float thickness)

πŸŽ€ DESCRIPTION πŸŽ€

It draws an outlined rounded rectangle. Not filled, okay? Just the outline, the lil border vibe πŸ’… (if you want the filled one, that's a whole other function, scroll down to SEE ALSO babes).

Here's the parameters breakdown, no cap:

  • x1, y1, x2, y2 β€” the upper left and lower right points of the rectangle 🫢
  • color β€” the color of the rectangle, obviously πŸ’œ
  • rx, ry β€” the radii of the round πŸ¦‹ (yes, both of them, x and y, because circles are so last season)
  • thickness β€” thickness of the lines, and listen: pass <= 0 to draw hairline lines ✨
not me warning you that the thickness thing is a real gotcha β€” if you want hairlines, go <= 0, fr fr 😭

🌈 SEE ALSO 🌈


okay that's the whole page bestie, go forth and draw your cute little rounded rectangles, you're gonna slay πŸ‘‘

this was brought to you by the Allegro reference manual β€” al_draw_rounded_rectangle(3alleg5), mwah πŸ’–βœ¨

πŸ“¦ where this page comes from