summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTofu Linden <tofu.linden@lindenlab.com>2010-05-20 11:38:57 +0100
committerTofu Linden <tofu.linden@lindenlab.com>2010-05-20 11:38:57 +0100
commit13d2501c847929ce9ee155dbb4dcfcf166710d3e (patch)
tree8e67e3372d683fef3c4ee4d93d00c1a35bc4c486
parent42796c938ba713b8f3aaff1b5d43d54021e223b8 (diff)
SNOW-207/DEV-42245 : FIXED : Texture loading on sculpty plants is failing making content appear to be of poor quality.
Patch by Thickbrick, reviewed by me.
-rw-r--r--doc/contributions.txt1
-rw-r--r--indra/newview/llface.cpp15
2 files changed, 13 insertions, 3 deletions
diff --git a/doc/contributions.txt b/doc/contributions.txt
index 5f209a6675..3f33763ce0 100644
--- a/doc/contributions.txt
+++ b/doc/contributions.txt
@@ -608,6 +608,7 @@ tenebrous pau
Tharax Ferraris
VWR-605
Thickbrick Sleaford
+ SNOW-207
VWR-7109
VWR-9287
VWR-13483
diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp
index a1336815f7..e0e5b32299 100644
--- a/indra/newview/llface.cpp
+++ b/indra/newview/llface.cpp
@@ -1376,9 +1376,18 @@ F32 LLFace::getTextureVirtualSize()
texel_area = 1.f;
}
- //apply texel area to face area to get accurate ratio
- //face_area /= llclamp(texel_area, 1.f/64.f, 16.f);
- F32 face_area = mPixelArea / llclamp(texel_area, 0.015625f, 128.f);
+ F32 face_area;
+ if (mVObjp->isSculpted() && texel_area > 1.f)
+ {
+ //sculpts can break assumptions about texel area
+ face_area = mPixelArea;
+ }
+ else
+ {
+ //apply texel area to face area to get accurate ratio
+ //face_area /= llclamp(texel_area, 1.f/64.f, 16.f);
+ face_area = mPixelArea / llclamp(texel_area, 0.015625f, 128.f);
+ }
if(face_area > LLViewerTexture::sMaxSmallImageSize)
{