Verified Commit 497a0946 authored by Mateusz Zalega's avatar Mateusz Zalega Committed by Rahix
Browse files

fix(gfx): Fix unwanted circle clipping



Signed-off-by: Mateusz Zalega's avatarMateusz Zalega <mateusz@appliedsourcery.com>
parent 1791d5cd
......@@ -127,8 +127,8 @@ void gfx_clear(struct gfx_region *reg)
void gfx_circle(struct gfx_region *reg, int x, int y, int r, int t, Color c)
{
for (int y_ = y - r; y_ <= y + r; y_++) {
for (int x_ = x - r; x_ <= x + r; x_++) {
for (int y_ = y - r - t; y_ <= y + r + t; y_++) {
for (int x_ = x - r - t; x_ <= x + r + t; x_++) {
int dx = (x_ - x) * (x_ - x);
int dy = (y_ - y) * (y_ - y);
int outer = (r + t) * (r + t);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment