From 3d7c1000625af4089476d14d1a8110842a23a104 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Mon, 22 Apr 2013 13:59:25 -0500 Subject: NORSPEC-141 Back out a change that seems to cause shadow artifacts on rigged attachments. --- .../shaders/class1/avatar/objectSkinV.glsl | 26 +++++++++------------- indra/newview/pipeline.cpp | 1 - 2 files changed, 10 insertions(+), 17 deletions(-) (limited to 'indra') diff --git a/indra/newview/app_settings/shaders/class1/avatar/objectSkinV.glsl b/indra/newview/app_settings/shaders/class1/avatar/objectSkinV.glsl index ff30560adc..2745d5fd95 100644 --- a/indra/newview/app_settings/shaders/class1/avatar/objectSkinV.glsl +++ b/indra/newview/app_settings/shaders/class1/avatar/objectSkinV.glsl @@ -30,24 +30,18 @@ uniform mat4 matrixPalette[64]; mat4 getObjectSkinnedTransform() { + int i; - float w0 = fract(weight4.x); - float w1 = fract(weight4.y); - float w2 = fract(weight4.z); - float w3 = fract(weight4.w); - - int i0 = int(floor(weight4.x)); - int i1 = int(floor(weight4.y)); - int i2 = int(floor(weight4.z)); - int i3 = int(floor(weight4.w)); - - //float scale = 1.0/(w.x+w.y+w.z+w.w); - //w *= scale; + vec4 w = fract(weight4); + vec4 index = floor(weight4); + + float scale = 1.0/(w.x+w.y+w.z+w.w); + w *= scale; - mat4 mat = matrixPalette[i0]*w0; - mat += matrixPalette[i1]*w1; - mat += matrixPalette[i2]*w2; - mat += matrixPalette[i3]*w3; + mat4 mat = matrixPalette[int(index.x)]*w.x; + mat += matrixPalette[int(index.y)]*w.y; + mat += matrixPalette[int(index.z)]*w.z; + mat += matrixPalette[int(index.w)]*w.w; return mat; } diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index ca5adc6180..a2f57c5720 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -10040,7 +10040,6 @@ void LLPipeline::generateSunShadow(LLCamera& camera) { static LLCullResult result[4]; - //LLGLEnable enable(GL_DEPTH_CLAMP_NV); renderShadow(view[j], proj[j], shadow_cam, result[j], TRUE, TRUE, target_width); } -- cgit v1.2.3 From 95672cabb98fb311010cf3ff5571b3422b4dec71 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Tue, 23 Apr 2013 12:50:47 -0500 Subject: NORSPEC-142 Fix for unusable performance on GTX 285 --- indra/newview/pipeline.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'indra') diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index a2f57c5720..9b7608e197 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -917,6 +917,11 @@ bool LLPipeline::allocateScreenBuffer(U32 resX, U32 resY, U32 samples) { screenFormat = GL_RGBA12; } + + if (gGLManager.mGLVersion < 4.f && gGLManager.mIsNVIDIA) + { + screenFormat = GL_RGBA16F_ARB; + } if (!mScreen.allocate(resX, resY, screenFormat, FALSE, FALSE, LLTexUnit::TT_RECT_TEXTURE, FALSE, samples)) return false; if (samples > 0) -- cgit v1.2.3