From 8a1e2f98cbbc242d2721deaa92ed34c3f3fcf788 Mon Sep 17 00:00:00 2001 From: Cosmic Linden Date: Wed, 24 Jan 2024 14:33:24 -0800 Subject: Fix vertex color indexing in material preview --- indra/newview/llgltfmaterialpreviewmgr.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/indra/newview/llgltfmaterialpreviewmgr.cpp b/indra/newview/llgltfmaterialpreviewmgr.cpp index 394f600a92..09a2954710 100644 --- a/indra/newview/llgltfmaterialpreviewmgr.cpp +++ b/indra/newview/llgltfmaterialpreviewmgr.cpp @@ -337,7 +337,7 @@ void set_preview_sphere_material(PreviewSphere& preview_sphere, LLPointermGLTFMaterial = material; LLVertexBuffer* buf = info->mVertexBuffer.get(); LLStrider colors; - const S32 count = info->mEnd - info->mStart; + const S32 count = info->mEnd - info->mStart + 1; buf->getColorStrider(colors, info->mStart, count); for (S32 i = 0; i < count; ++i) { -- cgit v1.2.3