From a28fff9391ef4ec84a931401fd2d9879d83497af Mon Sep 17 00:00:00 2001 From: fincs Date: Sun, 29 Jan 2017 21:44:12 +0100 Subject: [PATCH] Correct C3D_DrawElements with GPU_TRIANGLES --- source/drawElements.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/drawElements.c b/source/drawElements.c index ed06d87..a2f08e2 100644 --- a/source/drawElements.c +++ b/source/drawElements.c @@ -10,7 +10,7 @@ void C3D_DrawElements(GPU_Primitive_t primitive, int count, int type, const void C3Di_UpdateContext(); // Set primitive type - GPUCMD_AddMaskedWrite(GPUREG_PRIMITIVE_CONFIG, 2, primitive); + GPUCMD_AddMaskedWrite(GPUREG_PRIMITIVE_CONFIG, 2, primitive != GPU_TRIANGLES ? primitive : GPU_GEOMETRY_PRIM); // Start a new primitive (breaks off a triangle strip/fan) GPUCMD_AddWrite(GPUREG_RESTART_PRIMITIVE, 1); // Configure the index buffer