mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-06-25 07:10:43 -04:00
Remove a lot of static_cast<>s involving UI structs.
Also starting to get religion on using unsigned integers only when I want their wrapping/modulus behavior.
This commit is contained in:
parent
4c8550bb7d
commit
3f94591083
11 changed files with 28 additions and 76 deletions
|
@ -291,10 +291,7 @@ void ILI9341::fill_circle(
|
|||
const uint32_t d2 = x2 + y2;
|
||||
const bool inside = d2 < radius2;
|
||||
const auto color = inside ? foreground : background;
|
||||
draw_pixel({
|
||||
static_cast<ui::Coord>(x + center.x()),
|
||||
static_cast<ui::Coord>(y + center.y())
|
||||
}, color);
|
||||
draw_pixel({ x + center.x(), y + center.y() }, color);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue