summaryrefslogtreecommitdiff
path: root/indra/llprimitive
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llprimitive')
-rw-r--r--indra/llprimitive/llprimitive.cpp2
-rw-r--r--indra/llprimitive/lltextureentry.cpp11
-rw-r--r--indra/llprimitive/lltextureentry.h2
3 files changed, 11 insertions, 4 deletions
diff --git a/indra/llprimitive/llprimitive.cpp b/indra/llprimitive/llprimitive.cpp
index 8b470d235c..5dfce4ae16 100644
--- a/indra/llprimitive/llprimitive.cpp
+++ b/indra/llprimitive/llprimitive.cpp
@@ -83,7 +83,7 @@ const F32 LIGHT_MAX_CUTOFF = 180.f;
// reflection probes
const F32 REFLECTION_PROBE_MIN_AMBIANCE = 0.f;
-const F32 REFLECTION_PROBE_MAX_AMBIANCE = 1.f;
+const F32 REFLECTION_PROBE_MAX_AMBIANCE = 100.f;
const F32 REFLECTION_PROBE_DEFAULT_AMBIANCE = 0.f;
const F32 REFLECTION_PROBE_MIN_CLIP_DISTANCE = 0.f;
const F32 REFLECTION_PROBE_MAX_CLIP_DISTANCE = 1024.f;
diff --git a/indra/llprimitive/lltextureentry.cpp b/indra/llprimitive/lltextureentry.cpp
index a665db378b..17b1f4cf5c 100644
--- a/indra/llprimitive/lltextureentry.cpp
+++ b/indra/llprimitive/lltextureentry.cpp
@@ -559,10 +559,17 @@ void LLTextureEntry::setGLTFMaterial(LLGLTFMaterial* material, bool local_origin
}
}
-void LLTextureEntry::setGLTFMaterialOverride(LLGLTFMaterial* mat)
+S32 LLTextureEntry::setGLTFMaterialOverride(LLGLTFMaterial* mat)
{
llassert(mat == nullptr || getGLTFMaterial() != nullptr); // if override is not null, base material must not be null
- mGLTFMaterialOverrides = mat;
+ if (mat == mGLTFMaterialOverrides)
+ {
+ return TEM_CHANGE_NONE;
+ }
+
+ mGLTFMaterialOverrides = mat;
+
+ return TEM_CHANGE_TEXTURE;
}
S32 LLTextureEntry::setBaseMaterial()
diff --git a/indra/llprimitive/lltextureentry.h b/indra/llprimitive/lltextureentry.h
index 9a81181f3a..f5f2c0172d 100644
--- a/indra/llprimitive/lltextureentry.h
+++ b/indra/llprimitive/lltextureentry.h
@@ -200,7 +200,7 @@ public:
// GLTF override
LLGLTFMaterial* getGLTFMaterialOverride() const { return mGLTFMaterialOverrides; }
- void setGLTFMaterialOverride(LLGLTFMaterial* mat);
+ S32 setGLTFMaterialOverride(LLGLTFMaterial* mat);
// Clear most overrides so the render material better matches the material
// ID (preserve transforms). If the overrides become passthrough, set the
// overrides to nullptr.