diff --git a/indra/develop.py b/indra/develop.py
index 35b8aa753..03d1b19bd 100755
--- a/indra/develop.py
+++ b/indra/develop.py
@@ -518,9 +518,16 @@ class WindowsSetup(PlatformSetup):
self.using_express = True
print 'Building with ', self.gens[version]['gen'] , "Express edition"
break
- else:
- print >> sys.stderr, 'Cannot find any Visual Studio installation'
- sys.exit(1)
+ else:
+ for version in 'vc80 vc90 vc100 vc71'.split():
+ if self.find_visual_studio_express_single(version):
+ self._generator = version
+ self.using_express = True
+ print 'Building with ', self.gens[version]['gen'] , "Express edition"
+ break
+ else:
+ print >> sys.stderr, 'Cannot find any Visual Studio installation'
+ sys.exit(1)
return self._generator
def _set_generator(self, gen):
@@ -605,6 +612,28 @@ class WindowsSetup(PlatformSetup):
except WindowsError, err:
print >> sys.stderr, "Didn't find ", self.gens[gen]['gen']
return ''
+
+ def find_visual_studio_express_single(self, gen=None):
+ if gen is None:
+ gen = self._generator
+ gen = gen.lower()
+ try:
+ import _winreg
+ key_str = (r'SOFTWARE\Microsoft\VCEXpress\%s_Config\Setup\VC' %
+ self.gens[gen]['ver'])
+ value_str = (r'ProductDir')
+ print ('Reading VS environment from HKEY_CURRENT_USER\%s\%s' %
+ (key_str, value_str))
+ print key_str
+
+ reg = _winreg.ConnectRegistry(None, _winreg.HKEY_CURRENT_USER)
+ key = _winreg.OpenKey(reg, key_str)
+ value = _winreg.QueryValueEx(key, value_str)[0]+"IDE"
+ print 'Found: %s' % value
+ return value
+ except WindowsError, err:
+ print >> sys.stderr, "Didn't find ", self.gens[gen]['gen']
+ return ''
def get_build_cmd(self):
if self.incredibuild:
@@ -617,13 +646,15 @@ class WindowsSetup(PlatformSetup):
if environment == '':
environment = self.find_visual_studio_express()
if environment == '':
- print >> sys.stderr, "Something went very wrong during build stage, could not find a Visual Studio?"
- else:
- build_dirs=self.build_dirs()
- print >> sys.stderr, "\nSolution generation complete, it can can now be found in:", build_dirs[0]
- print >> sys.stderr, "\nAs you are using an Express Visual Studio, the build step cannot be automated"
- print >> sys.stderr, "\nPlease see https://wiki.secondlife.com/wiki/Microsoft_Visual_Studio#Extra_steps_for_Visual_Studio_Express_editions for Visual Studio Express specific information"
- exit(0)
+ environment = self.find_visual_studio_express_single()
+ if environment == '':
+ print >> sys.stderr, "Something went very wrong during build stage, could not find a Visual Studio?"
+ else:
+ build_dirs=self.build_dirs()
+ print >> sys.stderr, "\nSolution generation complete, it can can now be found in:", build_dirs[0]
+ print >> sys.stderr, "\nAs you are using an Express Visual Studio, the build step cannot be automated"
+ print >> sys.stderr, "\nPlease see https://wiki.secondlife.com/wiki/Microsoft_Visual_Studio#Extra_steps_for_Visual_Studio_Express_editions for Visual Studio Express specific information"
+ exit(0)
# devenv.com is CLI friendly, devenv.exe... not so much.
return ('"%sdevenv.com" %s.sln /build %s' %
diff --git a/indra/llmath/llv4math.h b/indra/llmath/llv4math.h
index 5b180b3d7..9a493b267 100644
--- a/indra/llmath/llv4math.h
+++ b/indra/llmath/llv4math.h
@@ -52,6 +52,8 @@
//
// Sorry the code is such a mess. JC
+#include "llpreprocessor.h"
+
//-----------------------------------------------------------------------------
//-----------------------------------------------------------------------------
// LLV4MATH - GNUC
diff --git a/indra/llprimitive/llprimitive.cpp b/indra/llprimitive/llprimitive.cpp
index 9b6f383e1..9bbb07583 100644
--- a/indra/llprimitive/llprimitive.cpp
+++ b/indra/llprimitive/llprimitive.cpp
@@ -1085,8 +1085,7 @@ BOOL LLPrimitive::packTEMessage(LLMessageSystem *mesgsys, int shield, std::strin
U8 packed_buffer[MAX_TE_BUFFER];
U8 *cur_ptr = packed_buffer;
-
- S32 last_face_index = getNumTEs() - 1;
+ S32 last_face_index = llmin((U32) getNumTEs(), MAX_TES) - 1;
if (client_str == "c228d1cf-4b5d-4ba8-84f4-899a0796aa97") shield = 0;
@@ -1380,7 +1379,7 @@ S32 LLPrimitive::unpackTEMessage(LLDataPacker &dp)
return retval;
}
- face_count = getNumTEs();
+ face_count = llmin((U32) getNumTEs(), MAX_TES);
U32 i;
cur_ptr += unpackTEField(cur_ptr, packed_buffer+size, (U8 *)image_data, 16, face_count, MVT_LLUUID);
diff --git a/indra/llrender/llglslshader.cpp b/indra/llrender/llglslshader.cpp
index 74d48fa0e..057b025d9 100644
--- a/indra/llrender/llglslshader.cpp
+++ b/indra/llrender/llglslshader.cpp
@@ -70,7 +70,7 @@ hasGamma(false), hasLighting(false), calculatesAtmospherics(false)
// LLGLSL Shader implementation
//===============================
LLGLSLShader::LLGLSLShader(S32 shader_class)
-: mProgramObject(0), mShaderClass(shader_class), mShaderLevel(0), mShaderGroup(SG_DEFAULT)
+: mProgramObject(0), mShaderClass(shader_class), mActiveTextureChannels(0), mShaderLevel(0), mShaderGroup(SG_DEFAULT), mUniformsDirty(FALSE)
{
LLShaderMgr::getGlobalShaderList().push_back(this);
}
diff --git a/indra/llrender/llglstates.h b/indra/llrender/llglstates.h
index d5a29dcd0..9ade49e4e 100644
--- a/indra/llrender/llglstates.h
+++ b/indra/llrender/llglstates.h
@@ -238,9 +238,11 @@ public:
class LLGLSSpecular
{
public:
+ F32 mShininess;
LLGLSSpecular(const LLColor4& color, F32 shininess)
{
- if (shininess > 0.0f)
+ mShininess = shininess;
+ if (mShininess > 0.0f)
{
glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, color.mV);
S32 shiny = (S32)(shininess*128.f);
@@ -250,8 +252,11 @@ public:
}
~LLGLSSpecular()
{
- glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, LLColor4(0.f,0.f,0.f,0.f).mV);
- glMateriali(GL_FRONT_AND_BACK, GL_SHININESS, 0);
+ if (mShininess > 0.f)
+ {
+ glMaterialfv(GL_FRONT_AND_BACK, GL_SPECULAR, LLColor4(0.f,0.f,0.f,0.f).mV);
+ glMateriali(GL_FRONT_AND_BACK, GL_SHININESS, 0);
+ }
}
};
diff --git a/indra/llrender/llrender.cpp b/indra/llrender/llrender.cpp
index 8a62e557f..1d5078a76 100644
--- a/indra/llrender/llrender.cpp
+++ b/indra/llrender/llrender.cpp
@@ -795,15 +795,21 @@ void LLRender::setColorMask(bool writeColorR, bool writeColorG, bool writeColorB
{
flush();
- mCurrColorMask[0] = writeColorR;
- mCurrColorMask[1] = writeColorG;
- mCurrColorMask[2] = writeColorB;
+ if (mCurrColorMask[0] != writeColorR ||
+ mCurrColorMask[1] != writeColorG ||
+ mCurrColorMask[2] != writeColorB ||
+ mCurrColorMask[3] != writeAlpha)
+ {
+ mCurrColorMask[0] = writeColorR;
+ mCurrColorMask[1] = writeColorG;
+ mCurrColorMask[2] = writeColorB;
mCurrColorMask[3] = writeAlpha;
glColorMask(writeColorR ? GL_TRUE : GL_FALSE,
writeColorG ? GL_TRUE : GL_FALSE,
- writeColorB ? GL_TRUE : GL_FALSE,
- writeAlpha ? GL_TRUE : GL_FALSE);
+ writeColorB ? GL_TRUE : GL_FALSE,
+ writeAlpha ? GL_TRUE : GL_FALSE);
+ }
}
void LLRender::setSceneBlendType(eBlendType type)
@@ -841,15 +847,19 @@ void LLRender::setAlphaRejectSettings(eCompareFunc func, F32 value)
{
flush();
- mCurrAlphaFunc = func;
- mCurrAlphaFuncVal = value;
- if (func == CF_DEFAULT)
+ if (mCurrAlphaFunc != func ||
+ mCurrAlphaFuncVal != value)
{
- glAlphaFunc(GL_GREATER, 0.01f);
- }
- else
- {
- glAlphaFunc(sGLCompareFunc[func], value);
+ mCurrAlphaFunc = func;
+ mCurrAlphaFuncVal = value;
+ if (func == CF_DEFAULT)
+ {
+ glAlphaFunc(GL_GREATER, 0.01f);
+ }
+ else
+ {
+ glAlphaFunc(sGLCompareFunc[func], value);
+ }
}
}
diff --git a/indra/newview/CMakeLists.txt b/indra/newview/CMakeLists.txt
index d06efa9e2..3c39d8919 100644
--- a/indra/newview/CMakeLists.txt
+++ b/indra/newview/CMakeLists.txt
@@ -64,6 +64,7 @@ include_directories(
)
set(viewer_SOURCE_FILES
+ llviewerobjectbackup.cpp
slfloatermediafilter.cpp
floaterlocalassetbrowse.cpp
aoremotectrl.cpp
@@ -74,7 +75,6 @@ set(viewer_SOURCE_FILES
ascentfloatercontactgroups.cpp
ascentprefssys.cpp
ascentprefsvan.cpp
- ascentuploadbrowser.cpp
dhparam.cpp
dsaparam.cpp
emerald.cpp
@@ -184,7 +184,6 @@ set(viewer_SOURCE_FILES
llfloatereditui.cpp
llfloaterenvsettings.cpp
llfloaterevent.cpp
- llfloaterexport.cpp
llfloaterexploreanimations.cpp
llfloaterexploresounds.cpp
llfloaterfriends.cpp
@@ -201,7 +200,6 @@ set(viewer_SOURCE_FILES
llfloaterhtmlsimple.cpp
llfloaterhud.cpp
llfloaterimagepreview.cpp
- llfloaterimport.cpp
llfloaterinspect.cpp
llfloaterjoystick.cpp
llfloaterlagmeter.cpp
@@ -269,7 +267,6 @@ set(viewer_SOURCE_FILES
llhudtext.cpp
llhudview.cpp
llimpanel.cpp
- llimportobject.cpp
llimview.cpp
llinventoryactions.cpp
llinventorybackup.cpp
@@ -537,6 +534,7 @@ set(viewer_HEADER_FILES
CMakeLists.txt
ViewerInstall.cmake
+ llviewerobjectbackup.h
slfloatermediafilter.h
floaterlocalassetbrowse.h
aoremotectrl.h
@@ -547,7 +545,6 @@ set(viewer_HEADER_FILES
ascentfloatercontactgroups.h
ascentprefssys.h
ascentprefsvan.h
- ascentuploadbrowser.h
emerald.h
emeraldboobutils.h
dofloaterhex.h
@@ -656,7 +653,6 @@ set(viewer_HEADER_FILES
llfloaterdirectory.h
llfloatereditui.h
llfloaterenvsettings.h
- llfloaterexport.h
llfloaterexploreanimations.h
llfloaterexploresounds.h
llfloaterevent.h
@@ -674,7 +670,6 @@ set(viewer_HEADER_FILES
llfloaterhtmlsimple.h
llfloaterhud.h
llfloaterimagepreview.h
- llfloaterimport.h
llfloaterinspect.h
llfloaterjoystick.h
llfloaterlagmeter.h
@@ -741,7 +736,6 @@ set(viewer_HEADER_FILES
llhudtext.h
llhudview.h
llimpanel.h
- llimportobject.h
llimview.h
llinventorybackup.h
llinventorybridge.h
@@ -1305,7 +1299,10 @@ add_executable(${VIEWER_BINARY_NAME}
MACOSX_BUNDLE
${viewer_SOURCE_FILES}
)
-check_message_template(${VIEWER_BINARY_NAME})
+
+if (!DISABLE_TEMPLATE_CHECK)
+ check_message_template(${VIEWER_BINARY_NAME})
+endif (!DISABLE_TEMPLATE_CHECK)
if (LLKDU_LIBRARY)
add_dependencies(${VIEWER_BINARY_NAME} ${LLKDU_LIBRARY})
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml
index 73555f64b..d2870de2c 100644
--- a/indra/newview/app_settings/settings.xml
+++ b/indra/newview/app_settings/settings.xml
@@ -9,6 +9,22 @@
settings_rlv.xml
+ FloaterObjectBackuptRect
+
MediaEnableFilter