From 13a9aca88ab1efa4b4988080c48d445cd79f6503 Mon Sep 17 00:00:00 2001 From: Stuart Carnie Date: Thu, 12 Jul 2018 23:15:24 -0700 Subject: [PATCH] fix(Metal): Render search box correctly --- gfx/common/metal/MenuDisplay.m | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gfx/common/metal/MenuDisplay.m b/gfx/common/metal/MenuDisplay.m index 69a299c3c7..cde9edc265 100644 --- a/gfx/common/metal/MenuDisplay.m +++ b/gfx/common/metal/MenuDisplay.m @@ -32,10 +32,10 @@ + (const float *)defaultVertices { static float dummy[] = { - 0.0f, 1.0f, - 1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f, + 0.0f, 1.0f, + 1.0f, 1.0f, }; return &dummy[0]; } @@ -145,7 +145,7 @@ SpriteVertex *pv = (SpriteVertex *)range.data; for (unsigned i = 0; i < draw->coords->vertices; i++, pv++) { - pv->position = simd_make_float2(vertex[0], vertex[1]); + pv->position = simd_make_float2(vertex[0], 1.0f - vertex[1]); vertex += 2; pv->texCoord = simd_make_float2(tex_coord[0], tex_coord[1]);