From ea0e3704a8aacf87f20ba87e3b33bc4b3966c731 Mon Sep 17 00:00:00 2001 From: Franklin Wei Date: Sun, 11 Aug 2024 23:34:57 -0400 Subject: puzzles: resync with upstream 262f709. This is the first resync with a fully unmodified upstream repo. This includes a new scanline polygon renderer in the upstream puzzles distribution. This allows us to get rid of the monstrosity of a polygon renderer we had been shipping in rockbox.c. Change-Id: I23628c74bb5ff7a9e7932bf16d68a1c867c49969 --- apps/plugins/puzzles/src/signpost.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'apps/plugins/puzzles/src/signpost.c') diff --git a/apps/plugins/puzzles/src/signpost.c b/apps/plugins/puzzles/src/signpost.c index 4d2f5849fd..9aed67bb4a 100644 --- a/apps/plugins/puzzles/src/signpost.c +++ b/apps/plugins/puzzles/src/signpost.c @@ -1895,9 +1895,8 @@ static void draw_star(drawing *dr, int cx, int cy, int rad, int npoints, coords = snewn(npoints * 2 * 2, int); for (n = 0; n < npoints * 2; n++) { - /* hack to accomodate rockbox's concave polygon drawing */ - a = 2.0 * PI * ((double)n / ((double)npoints * 2.0)) + angle_offset - PI / npoints; - r = (n % 2 == 0) ? (double)rad/2.0 : (double)rad; + a = 2.0 * PI * ((double)n / ((double)npoints * 2.0)) + angle_offset; + r = (n % 2) ? (double)rad/2.0 : (double)rad; /* We're rotating the point at (0, -r) by a degrees */ coords[2*n+0] = cx + (int)( r * sin(a)); -- cgit v1.2.3