From fb9cb882728f512216538d185ff3caeff6f8b148 Mon Sep 17 00:00:00 2001
From: Drake Arconis <drake@alchemyviewer.org>
Date: Sat, 19 Nov 2016 22:25:39 -0500
Subject: [PATCH] STORM-2143 Correct vertex winding of stars

---
 doc/contributions.txt       |  2 ++
 indra/newview/llvowlsky.cpp | 12 ++++++------
 2 files changed, 8 insertions(+), 6 deletions(-)

diff --git a/doc/contributions.txt b/doc/contributions.txt
index af2166528b..5d5f31a9d7 100755
--- a/doc/contributions.txt
+++ b/doc/contributions.txt
@@ -1253,6 +1253,7 @@ Shnurui Troughton
 Shyotl Kuhr
 	MAINT-1138
 	MAINT-2334
+    STORM-2143
 Siana Gearz
 	STORM-960
 	STORM-1088
@@ -1286,6 +1287,7 @@ Sovereign Engineer
     MAINT-6107
     STORM-2107
     MAINT-6218
+    STORM-2143
 SpacedOut Frye
 	VWR-34
 	VWR-45
diff --git a/indra/newview/llvowlsky.cpp b/indra/newview/llvowlsky.cpp
index 90bc6509a6..16130b5ca7 100644
--- a/indra/newview/llvowlsky.cpp
+++ b/indra/newview/llvowlsky.cpp
@@ -810,18 +810,18 @@ BOOL LLVOWLSky::updateStarGeometry(LLDrawable *drawable)
 		up *= sc;
 
 		*(verticesp++)  = mStarVertices[vtx];
-		*(verticesp++) = mStarVertices[vtx]+left;
+		*(verticesp++) = mStarVertices[vtx]+up;
 		*(verticesp++) = mStarVertices[vtx]+left+up;
-		*(verticesp++) = mStarVertices[vtx]+left;
+		*(verticesp++)  = mStarVertices[vtx];
 		*(verticesp++) = mStarVertices[vtx]+left+up;
-		*(verticesp++) = mStarVertices[vtx]+up;
+		*(verticesp++) = mStarVertices[vtx]+left;
 
-		*(texcoordsp++) = LLVector2(0,0);
-		*(texcoordsp++) = LLVector2(0,1);
+		*(texcoordsp++) = LLVector2(1,0);
 		*(texcoordsp++) = LLVector2(1,1);
 		*(texcoordsp++) = LLVector2(0,1);
-		*(texcoordsp++) = LLVector2(1,1);
 		*(texcoordsp++) = LLVector2(1,0);
+		*(texcoordsp++) = LLVector2(0,1);
+		*(texcoordsp++) = LLVector2(0,0);
 
 		*(colorsp++)    = LLColor4U(mStarColors[vtx]);
 		*(colorsp++)    = LLColor4U(mStarColors[vtx]);
-- 
GitLab