summaryrefslogtreecommitdiff
path: root/indra/llprimitive
diff options
context:
space:
mode:
authorJonathan "Geenz" Goodman <geenz@geenzo.com>2023-03-13 08:06:17 -0700
committerJonathan "Geenz" Goodman <geenz@geenzo.com>2023-03-13 08:06:17 -0700
commit75dea34e3f80b054c56c38c880166d5e610eef88 (patch)
tree8a8a54cb3e446213b33dcdd64c0c89d3c47369b4 /indra/llprimitive
parentf3ce17701e8dbbbc7a0e8e73c740b161bb2f36c0 (diff)
parent0e178e12562b95915a9a775cd40d3bb44729332c (diff)
Merge branch 'DRTVWR-559' of https://github.com/secondlife/viewer into DRTVWR-559
Diffstat (limited to 'indra/llprimitive')
-rw-r--r--indra/llprimitive/llgltfloader.cpp4
-rw-r--r--indra/llprimitive/llgltfmaterial.h3
2 files changed, 5 insertions, 2 deletions
diff --git a/indra/llprimitive/llgltfloader.cpp b/indra/llprimitive/llgltfloader.cpp
index fd304f7bc9..7394f99794 100644
--- a/indra/llprimitive/llgltfloader.cpp
+++ b/indra/llprimitive/llgltfloader.cpp
@@ -106,10 +106,12 @@ bool LLGLTFLoader::OpenFile(const std::string &filename)
tinygltf::TinyGLTF loader;
std::string error_msg;
std::string warn_msg;
+ std::string filename_lc(filename);
+ LLStringUtil::toLower(filename_lc);
// Load a tinygltf model fom a file. Assumes that the input filename has already been
// been sanitized to one of (.gltf , .glb) extensions, so does a simple find to distinguish.
- if (std::string::npos == filename.rfind(".gltf"))
+ if (std::string::npos == filename_lc.rfind(".gltf"))
{ // file is binary
mGltfLoaded = loader.LoadBinaryFromFile(&mGltfModel, &error_msg, &warn_msg, filename);
}
diff --git a/indra/llprimitive/llgltfmaterial.h b/indra/llprimitive/llgltfmaterial.h
index e701b62fdc..b453b91e67 100644
--- a/indra/llprimitive/llgltfmaterial.h
+++ b/indra/llprimitive/llgltfmaterial.h
@@ -98,7 +98,8 @@ public:
std::array<TextureTransform, GLTF_TEXTURE_INFO_COUNT> mTextureTransform;
- // NOTE : initialize values to defaults according to the GLTF spec
+ // NOTE: initialize values to defaults according to the GLTF spec
+ // NOTE: these values should be in linear color space
LLColor4 mBaseColor = LLColor4(1, 1, 1, 1);
LLColor3 mEmissiveColor = LLColor3(0, 0, 0);