From 2af4f317122d73dd459e0c9c3aed14192c08c186 Mon Sep 17 00:00:00 2001 From: Jeffery Myers Date: Sun, 10 Nov 2024 13:04:58 -0800 Subject: [PATCH] Fix the X axis of the second vertex of the Y negative cap of a cylinders, triangle fan (#4478) --- src/rmodels.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rmodels.c b/src/rmodels.c index 6ddb53ae..04f7210f 100644 --- a/src/rmodels.c +++ b/src/rmodels.c @@ -603,7 +603,7 @@ void DrawCylinder(Vector3 position, float radiusTop, float radiusBottom, float h for (int i = 0; i < sides; i++) { rlVertex3f(0, 0, 0); - rlVertex3f(sinf(DEG2RAD*i*angleStep)*radiusBottom, 0, cosf(DEG2RAD*(i+1)*angleStep)*radiusBottom); + rlVertex3f(sinf(DEG2RAD*(i+1)*angleStep)*radiusBottom, 0, cosf(DEG2RAD*(i+1)*angleStep)*radiusBottom); rlVertex3f(sinf(DEG2RAD*i*angleStep)*radiusBottom, 0, cosf(DEG2RAD*i*angleStep)*radiusBottom); }