summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
authorLoren Shih <seraph@lindenlab.com>2011-02-01 11:16:43 -0500
committerLoren Shih <seraph@lindenlab.com>2011-02-01 11:16:43 -0500
commit293b35f000ca4e8a4bcf85dc4782b2a72d1887ea (patch)
tree70c1731808e5449a56b8a38007c6c952bb559f48 /indra/newview
parentd0cba9e9194841e8867afcbd02b3792b652756ab (diff)
parentee39db49a38a626e72e1924e4c157b16d90e8ee6 (diff)
Automated merge from mesh-development
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/llagentpilot.cpp10
-rw-r--r--indra/newview/llappviewer.cpp12
-rw-r--r--indra/newview/llfirstuse.cpp58
-rw-r--r--indra/newview/llfirstuse.h9
-rwxr-xr-xindra/newview/llfloatermodelpreview.cpp13
-rw-r--r--indra/newview/llfloatertools.cpp4
-rw-r--r--indra/newview/llmanipscale.cpp23
-rw-r--r--indra/newview/llmanipscale.h3
-rwxr-xr-xindra/newview/llmeshrepository.cpp16
-rw-r--r--indra/newview/llmeshrepository.h2
-rw-r--r--indra/newview/llpanelobject.cpp11
-rw-r--r--indra/newview/llselectmgr.cpp4
-rw-r--r--indra/newview/llspatialpartition.cpp81
-rw-r--r--indra/newview/llspatialpartition.h1
-rw-r--r--indra/newview/llviewercontrol.cpp7
-rw-r--r--indra/newview/llviewermenu.cpp4
-rw-r--r--indra/newview/llviewermenufile.cpp12
-rw-r--r--indra/newview/llviewerwindow.cpp6
-rw-r--r--indra/newview/llvoavatar.cpp9
-rw-r--r--indra/newview/llvoavatar.h1
-rw-r--r--indra/newview/llvoavatarself.cpp3
-rw-r--r--indra/newview/llvovolume.cpp19
-rwxr-xr-xindra/newview/pipeline.cpp138
-rw-r--r--indra/newview/pipeline.h2
-rw-r--r--indra/newview/skins/default/xui/en/menu_inventory_add.xml2
-rw-r--r--indra/newview/skins/default/xui/en/menu_viewer.xml14
-rw-r--r--indra/newview/skins/default/xui/en/notifications.xml6
27 files changed, 344 insertions, 126 deletions
diff --git a/indra/newview/llagentpilot.cpp b/indra/newview/llagentpilot.cpp
index 13e1023185..afeba6bdf0 100644
--- a/indra/newview/llagentpilot.cpp
+++ b/indra/newview/llagentpilot.cpp
@@ -178,6 +178,8 @@ void LLAgentPilot::stopPlayback()
}
}
+#define SKIP_PILOT_LOGGING 1
+
void LLAgentPilot::updateTarget()
{
if (mPlaying)
@@ -195,7 +197,9 @@ void LLAgentPilot::updateTarget()
{
if (!mStarted)
{
+#if SKIP_PILOT_LOGGING
llinfos << "At start, beginning playback" << llendl;
+#endif
mTimer.reset();
mStarted = TRUE;
}
@@ -218,17 +222,23 @@ void LLAgentPilot::updateTarget()
{
if ((mNumRuns < 0) || (mNumRuns > 0))
{
+#if SKIP_PILOT_LOGGING
llinfos << "Looping, restarting playback" << llendl;
+#endif
startPlayback();
}
else if (mQuitAfterRuns)
{
+#if SKIP_PILOT_LOGGING
llinfos << "Done with all runs, quitting viewer!" << llendl;
+#endif
LLAppViewer::instance()->forceQuit();
}
else
{
+#if SKIP_PILOT_LOGGING
llinfos << "Done with all runs, disabling pilot" << llendl;
+#endif
stopPlayback();
}
}
diff --git a/indra/newview/llappviewer.cpp b/indra/newview/llappviewer.cpp
index 2d4838814e..e74a7a84c3 100644
--- a/indra/newview/llappviewer.cpp
+++ b/indra/newview/llappviewer.cpp
@@ -897,6 +897,18 @@ bool LLAppViewer::init()
return 0;
}
+ // Without SSE2 support we will crash almost immediately, warn here.
+ if (!gSysCPU.hasSSE2())
+ {
+ // can't use an alert here since we're exiting and
+ // all hell breaks lose.
+ OSMessageBox(
+ LLNotifications::instance().getGlobalString("UnsupportedCPUSSE2"),
+ LLStringUtil::null,
+ OSMB_OK);
+ return 0;
+ }
+
// alert the user if they are using unsupported hardware
if(!gSavedSettings.getBOOL("AlertedUnsupportedHardware"))
{
diff --git a/indra/newview/llfirstuse.cpp b/indra/newview/llfirstuse.cpp
index 4c17199895..4d252dc662 100644
--- a/indra/newview/llfirstuse.cpp
+++ b/indra/newview/llfirstuse.cpp
@@ -41,35 +41,36 @@
// static
-std::set<std::string> LLFirstUse::sConfigVariables;
+//std::set<std::string> LLFirstUse::sConfigVariables;
+std::set<std::string> LLFirstUse::sConfigVariablesEnabled;
// static
-void LLFirstUse::addConfigVariable(const std::string& var)
-{
- sConfigVariables.insert(var);
-}
+//void LLFirstUse::addConfigVariable(const std::string& var)
+//{
+// sConfigVariables.insert(var);
+//}
// static
-void LLFirstUse::disableFirstUse()
-{
- // Set all first-use warnings to disabled
- for (std::set<std::string>::iterator iter = sConfigVariables.begin();
- iter != sConfigVariables.end(); ++iter)
- {
- gWarningSettings.setBOOL(*iter, FALSE);
- }
-}
+//void LLFirstUse::disableFirstUse()
+//{
+// // Set all first-use warnings to disabled
+// for (std::set<std::string>::iterator iter = sConfigVariables.begin();
+// iter != sConfigVariables.end(); ++iter)
+// {
+// gWarningSettings.setBOOL(*iter, FALSE);
+// }
+//}
// static
-void LLFirstUse::resetFirstUse()
-{
- // Set all first-use warnings to disabled
- for (std::set<std::string>::iterator iter = sConfigVariables.begin();
- iter != sConfigVariables.end(); ++iter)
- {
- gWarningSettings.setBOOL(*iter, TRUE);
- }
-}
+//void LLFirstUse::resetFirstUse()
+//{
+// // Set all first-use warnings to disabled
+// for (std::set<std::string>::iterator iter = sConfigVariables.begin();
+// iter != sConfigVariables.end(); ++iter)
+// {
+// gWarningSettings.setBOOL(*iter, TRUE);
+// }
+//}
// static
void LLFirstUse::otherAvatarChatFirst(bool enable)
@@ -151,13 +152,21 @@ void LLFirstUse::firstUseNotification(const std::string& control_var, bool enabl
if (enable)
{
+ if(sConfigVariablesEnabled.find(control_var) != sConfigVariablesEnabled.end())
+ {
+ return ; //already added
+ }
+
if (gSavedSettings.getBOOL("EnableUIHints"))
{
LL_DEBUGS("LLFirstUse") << "Trigger first use notification " << notification_name << LL_ENDL;
// if notification doesn't already exist and this notification hasn't been disabled...
if (gWarningSettings.getBOOL(control_var))
- { // create new notification
+ {
+ sConfigVariablesEnabled.insert(control_var) ;
+
+ // create new notification
LLNotifications::instance().add(LLNotification::Params().name(notification_name).substitutions(args).payload(payload.with("control_var", control_var)));
}
}
@@ -169,7 +178,6 @@ void LLFirstUse::firstUseNotification(const std::string& control_var, bool enabl
// redundantly clear settings var here, in case there are no notifications to cancel
gWarningSettings.setBOOL(control_var, FALSE);
}
-
}
// static
diff --git a/indra/newview/llfirstuse.h b/indra/newview/llfirstuse.h
index 81659988e6..489f58626a 100644
--- a/indra/newview/llfirstuse.h
+++ b/indra/newview/llfirstuse.h
@@ -78,11 +78,11 @@ class LLFirstUse
public:
// Add a config variable to be reset on resetFirstUse()
- static void addConfigVariable(const std::string& var);
+ //static void addConfigVariable(const std::string& var);
// Sets all controls back to show the dialogs.
- static void disableFirstUse();
- static void resetFirstUse();
+ //static void disableFirstUse();
+ //static void resetFirstUse();
static void otherAvatarChatFirst(bool enable = true);
static void sit(bool enable = true);
@@ -98,7 +98,8 @@ public:
protected:
static void firstUseNotification(const std::string& control_var, bool enable, const std::string& notification_name, LLSD args = LLSD(), LLSD payload = LLSD());
- static std::set<std::string> sConfigVariables;
+ //static std::set<std::string> sConfigVariables;
+ static std::set<std::string> sConfigVariablesEnabled;
static void init();
static bool processNotification(const LLSD& notify);
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp
index cc2a8c8aac..dde470693c 100755
--- a/indra/newview/llfloatermodelpreview.cpp
+++ b/indra/newview/llfloatermodelpreview.cpp
@@ -2205,9 +2205,12 @@ U32 LLModelPreview::calcResourceCost()
rebuildUploadData();
- if ( mModelLoader->getLoadState() != LLModelLoader::ERROR_PARSING )
+ if (mFMP && mModelLoader)
{
- mFMP->childEnable("ok_btn");
+ if ( mModelLoader->getLoadState() != LLModelLoader::ERROR_PARSING )
+ {
+ mFMP->childEnable("ok_btn");
+ }
}
U32 cost = 0;
@@ -2215,7 +2218,7 @@ U32 LLModelPreview::calcResourceCost()
U32 num_points = 0;
U32 num_hulls = 0;
- F32 debug_scale = mFMP->childGetValue("import_scale").asReal();
+ F32 debug_scale = mFMP ? mFMP->childGetValue("import_scale").asReal() : 1.f;
F32 streaming_cost = 0.f;
F32 physics_cost = 0.f;
@@ -2270,9 +2273,7 @@ U32 LLModelPreview::calcResourceCost()
}
}
- //mFMP->childSetTextArg(info_name[LLModel::LOD_PHYSICS], "[HULLS]", llformat("%d",num_hulls));
- //mFMP->childSetTextArg(info_name[LLModel::LOD_PHYSICS], "[POINTS]", llformat("%d",num_points));
- F32 scale = mFMP->childGetValue("import_scale").asReal()*2.f;
+ F32 scale = mFMP ? mFMP->childGetValue("import_scale").asReal()*2.f : 2.f;
mDetailsSignal(mPreviewScale[0]*scale, mPreviewScale[1]*scale, mPreviewScale[2]*scale, streaming_cost, physics_cost);
diff --git a/indra/newview/llfloatertools.cpp b/indra/newview/llfloatertools.cpp
index 49e24f8e3d..c9b99d83ff 100644
--- a/indra/newview/llfloatertools.cpp
+++ b/indra/newview/llfloatertools.cpp
@@ -32,6 +32,7 @@
#include "llcoord.h"
//#include "llgl.h"
+#include "llagent.h"
#include "llagentcamera.h"
#include "llbutton.h"
#include "llcheckboxctrl.h"
@@ -463,7 +464,8 @@ void LLFloaterTools::refresh()
childSetEnabled("linked_set_cost", have_selection);
childSetEnabled("object_cost", have_selection);
- bool enable_mesh = gSavedSettings.getBOOL("MeshEnabled");
+ bool enable_mesh = gSavedSettings.getBOOL("MeshEnabled") &&
+ !gAgent.getRegion()->getCapability("GetMesh").empty();
getChildView("linked_set_count")->setVisible(enable_mesh);
getChildView("linked_set_cost")->setVisible(enable_mesh);
diff --git a/indra/newview/llmanipscale.cpp b/indra/newview/llmanipscale.cpp
index 060677f9f3..67ab7ab462 100644
--- a/indra/newview/llmanipscale.cpp
+++ b/indra/newview/llmanipscale.cpp
@@ -85,6 +85,17 @@ const LLManip::EManipPart MANIPULATOR_IDS[NUM_MANIPULATORS] =
};
+F32 get_default_max_prim_scale()
+{
+ if (gSavedSettings.getBOOL("MeshEnabled"))
+ {
+ return DEFAULT_MAX_PRIM_SCALE;
+ }
+ else
+ {
+ return DEFAULT_MAX_PRIM_SCALE_NO_MESH;
+ }
+}
// static
void LLManipScale::setUniform(BOOL b)
@@ -950,8 +961,8 @@ void LLManipScale::dragCorner( S32 x, S32 y )
mInSnapRegime = FALSE;
}
- F32 max_scale_factor = DEFAULT_MAX_PRIM_SCALE / MIN_PRIM_SCALE;
- F32 min_scale_factor = MIN_PRIM_SCALE / DEFAULT_MAX_PRIM_SCALE;
+ F32 max_scale_factor = get_default_max_prim_scale() / MIN_PRIM_SCALE;
+ F32 min_scale_factor = MIN_PRIM_SCALE / get_default_max_prim_scale();
// find max and min scale factors that will make biggest object hit max absolute scale and smallest object hit min absolute scale
for (LLObjectSelection::iterator iter = mObjectSelection->begin();
@@ -963,7 +974,7 @@ void LLManipScale::dragCorner( S32 x, S32 y )
{
const LLVector3& scale = selectNode->mSavedScale;
- F32 cur_max_scale_factor = llmin( DEFAULT_MAX_PRIM_SCALE / scale.mV[VX], DEFAULT_MAX_PRIM_SCALE / scale.mV[VY], DEFAULT_MAX_PRIM_SCALE / scale.mV[VZ] );
+ F32 cur_max_scale_factor = llmin( get_default_max_prim_scale() / scale.mV[VX], get_default_max_prim_scale() / scale.mV[VY], get_default_max_prim_scale() / scale.mV[VZ] );
max_scale_factor = llmin( max_scale_factor, cur_max_scale_factor );
F32 cur_min_scale_factor = llmax( MIN_PRIM_SCALE / scale.mV[VX], MIN_PRIM_SCALE / scale.mV[VY], MIN_PRIM_SCALE / scale.mV[VZ] );
@@ -1260,7 +1271,7 @@ void LLManipScale::stretchFace( const LLVector3& drag_start_agent, const LLVecto
F32 denom = axis * dir_local;
F32 desired_delta_size = is_approx_zero(denom) ? 0.f : (delta_local_mag / denom); // in meters
- F32 desired_scale = llclamp(selectNode->mSavedScale.mV[axis_index] + desired_delta_size, MIN_PRIM_SCALE, DEFAULT_MAX_PRIM_SCALE);
+ F32 desired_scale = llclamp(selectNode->mSavedScale.mV[axis_index] + desired_delta_size, MIN_PRIM_SCALE, get_default_max_prim_scale());
// propagate scale constraint back to position offset
desired_delta_size = desired_scale - selectNode->mSavedScale.mV[axis_index]; // propagate constraint back to position
@@ -1960,7 +1971,7 @@ F32 LLManipScale::partToMaxScale( S32 part, const LLBBox &bbox ) const
max_extent = bbox_extents.mV[i];
}
}
- max_scale_factor = bbox_extents.magVec() * DEFAULT_MAX_PRIM_SCALE / max_extent;
+ max_scale_factor = bbox_extents.magVec() * get_default_max_prim_scale() / max_extent;
if (getUniform())
{
@@ -1975,7 +1986,7 @@ F32 LLManipScale::partToMinScale( S32 part, const LLBBox &bbox ) const
{
LLVector3 bbox_extents = unitVectorToLocalBBoxExtent( partToUnitVector( part ), bbox );
bbox_extents.abs();
- F32 min_extent = DEFAULT_MAX_PRIM_SCALE;
+ F32 min_extent = get_default_max_prim_scale();
for (U32 i = VX; i <= VZ; i++)
{
if (bbox_extents.mV[i] > 0.f && bbox_extents.mV[i] < min_extent)
diff --git a/indra/newview/llmanipscale.h b/indra/newview/llmanipscale.h
index 5559f557c0..2762433abf 100644
--- a/indra/newview/llmanipscale.h
+++ b/indra/newview/llmanipscale.h
@@ -39,6 +39,9 @@
#include "llviewerobject.h"
#include "llbbox.h"
+
+F32 get_default_max_prim_scale();
+
class LLToolComposite;
class LLColor4;
diff --git a/indra/newview/llmeshrepository.cpp b/indra/newview/llmeshrepository.cpp
index b772999ee2..edcf249a21 100755
--- a/indra/newview/llmeshrepository.cpp
+++ b/indra/newview/llmeshrepository.cpp
@@ -2160,7 +2160,7 @@ S32 LLMeshRepository::update()
return size ;
}
-S32 LLMeshRepository::loadMesh(LLVOVolume* vobj, const LLVolumeParams& mesh_params, S32 detail)
+S32 LLMeshRepository::loadMesh(LLVOVolume* vobj, const LLVolumeParams& mesh_params, S32 detail, S32 last_lod)
{
if (detail < 0 || detail > 4)
{
@@ -2201,7 +2201,19 @@ S32 LLMeshRepository::loadMesh(LLVOVolume* vobj, const LLVolumeParams& mesh_para
if (group)
{
- //first see what the next lowest LOD available might be
+ //first, see if last_lod is available (don't transition down to avoid funny popping a la SH-641)
+ if (last_lod >= 0)
+ {
+ LLVolume* lod = group->refLOD(last_lod);
+ if (lod && !lod->isTetrahedron() && lod->getNumVolumeFaces() > 0)
+ {
+ group->derefLOD(lod);
+ return last_lod;
+ }
+ group->derefLOD(lod);
+ }
+
+ //next, see what the next lowest LOD available might be
for (S32 i = detail-1; i >= 0; --i)
{
LLVolume* lod = group->refLOD(i);
diff --git a/indra/newview/llmeshrepository.h b/indra/newview/llmeshrepository.h
index eccb82b661..b642a89192 100644
--- a/indra/newview/llmeshrepository.h
+++ b/indra/newview/llmeshrepository.h
@@ -456,7 +456,7 @@ public:
S32 update() ;
//mesh management functions
- S32 loadMesh(LLVOVolume* volume, const LLVolumeParams& mesh_params, S32 detail = 0);
+ S32 loadMesh(LLVOVolume* volume, const LLVolumeParams& mesh_params, S32 detail = 0, S32 last_lod = -1);
void notifyLoadedMeshes();
void notifyMeshLoaded(const LLVolumeParams& mesh_params, LLVolume* volume);
diff --git a/indra/newview/llpanelobject.cpp b/indra/newview/llpanelobject.cpp
index f1fd47f50e..8fa6beb474 100644
--- a/indra/newview/llpanelobject.cpp
+++ b/indra/newview/llpanelobject.cpp
@@ -1923,7 +1923,8 @@ void LLPanelObject::refresh()
mRootObject = NULL;
}
- bool enable_mesh = gSavedSettings.getBOOL("MeshEnabled");
+ bool enable_mesh = gSavedSettings.getBOOL("MeshEnabled") &&
+ !gAgent.getRegion()->getCapability("GetMesh").empty();
getChildView("label physicsshapetype")->setVisible(enable_mesh);
getChildView("Physics Shape Type Combo Ctrl")->setVisible(enable_mesh);
@@ -1933,10 +1934,10 @@ void LLPanelObject::refresh()
getChildView("Physics Density")->setVisible(enable_mesh);
getChildView("Physics Restitution")->setVisible(enable_mesh);
- // if mesh isn't enabled we want to the scale max to be 10
- getChild<LLSpinCtrl>("Scale X")->setMaxValue(enable_mesh ? 64 : 10);
- getChild<LLSpinCtrl>("Scale Y")->setMaxValue(enable_mesh ? 64 : 10);
- getChild<LLSpinCtrl>("Scale Z")->setMaxValue(enable_mesh ? 64 : 10);
+ F32 max_scale = DEFAULT_MAX_PRIM_SCALE_NO_MESH;
+ getChild<LLSpinCtrl>("Scale X")->setMaxValue(max_scale);
+ getChild<LLSpinCtrl>("Scale Y")->setMaxValue(max_scale);
+ getChild<LLSpinCtrl>("Scale Z")->setMaxValue(max_scale);
LLComboBox* sculpt_combo = getChild<LLComboBox>("sculpt type control");
BOOL found = sculpt_combo->itemExists("Mesh");
diff --git a/indra/newview/llselectmgr.cpp b/indra/newview/llselectmgr.cpp
index 44ccbe22f7..8ffbd5510d 100644
--- a/indra/newview/llselectmgr.cpp
+++ b/indra/newview/llselectmgr.cpp
@@ -5490,13 +5490,15 @@ void LLSelectNode::renderOneWireframe(const LLColor4& color)
glMatrixMode(GL_MODELVIEW);
gGL.pushMatrix();
-
+
BOOL is_hud_object = objectp->isHUDAttachment();
if (!is_hud_object)
{
glLoadIdentity();
glMultMatrixd(gGLModelView);
+ LLVector3 trans = objectp->getRegion()->getOriginAgent();
+ glTranslatef(trans.mV[0], trans.mV[1], trans.mV[2]);
}
if (drawable->isActive())
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp
index b9063b3c81..af6064ad20 100644
--- a/indra/newview/llspatialpartition.cpp
+++ b/indra/newview/llspatialpartition.cpp
@@ -64,6 +64,12 @@ const F32 SG_OCCLUSION_FUDGE = 0.25f;
static U32 sZombieGroups = 0;
U32 LLSpatialGroup::sNodeCount = 0;
+
+#define LL_TRACK_PENDING_OCCLUSION_QUERIES 0
+
+std::set<GLuint> LLSpatialGroup::sPendingQueries;
+
+
BOOL LLSpatialGroup::sNoDelete = FALSE;
static F32 sLastMaxTexPriority = 1.f;
@@ -81,6 +87,9 @@ protected:
virtual void releaseName(GLuint name)
{
+#if LL_TRACK_PENDING_OCCLUSION_QUERIES
+ LLSpatialGroup::sPendingQueries.erase(name);
+#endif
glDeleteQueriesARB(1, &name);
}
};
@@ -361,9 +370,15 @@ LLSpatialGroup::~LLSpatialGroup()
sNodeCount--;
- if (gGLManager.mHasOcclusionQuery && mOcclusionQuery[LLViewerCamera::sCurCameraID])
+ if (gGLManager.mHasOcclusionQuery)
{
- sQueryPool.release(mOcclusionQuery[LLViewerCamera::sCurCameraID]);
+ for (U32 i = 0; i < LLViewerCamera::NUM_CAMERAS; ++i)
+ {
+ if (mOcclusionQuery[i])
+ {
+ sQueryPool.release(mOcclusionQuery[i]);
+ }
+ }
}
mOcclusionVerts = NULL;
@@ -507,7 +522,7 @@ BOOL LLSpatialGroup::isRecentlyVisible() const
BOOL LLSpatialGroup::isVisible() const
{
- return mVisible[LLViewerCamera::sCurCameraID] == LLDrawable::getCurrentFrame() ? TRUE : FALSE;
+ return mVisible[LLViewerCamera::sCurCameraID] >= LLDrawable::getCurrentFrame() ? TRUE : FALSE;
}
void LLSpatialGroup::setVisible()
@@ -1096,12 +1111,23 @@ void LLSpatialGroup::setOcclusionState(U32 state, S32 mode)
for (U32 i = 0; i < LLViewerCamera::NUM_CAMERAS; i++)
{
mOcclusionState[i] |= state;
+
+ if ((state & DISCARD_QUERY) && mOcclusionQuery[i])
+ {
+ sQueryPool.release(mOcclusionQuery[i]);
+ mOcclusionQuery[i] = 0;
+ }
}
}
}
else
{
mOcclusionState[LLViewerCamera::sCurCameraID] |= state;
+ if ((state & DISCARD_QUERY) && mOcclusionQuery[LLViewerCamera::sCurCameraID])
+ {
+ sQueryPool.release(mOcclusionQuery[LLViewerCamera::sCurCameraID]);
+ mOcclusionQuery[LLViewerCamera::sCurCameraID] = 0;
+ }
}
}
@@ -1319,7 +1345,8 @@ F32 LLSpatialGroup::getUpdateUrgency() const
}
else
{
- return (gFrameTimeSeconds - mLastUpdateTime+4.f)/mDistance;
+ F32 time = gFrameTimeSeconds-mLastUpdateTime+4.f;
+ return time + (mObjectBounds[1].dot3(mObjectBounds[1]).getF32()+1.f)/mDistance;
}
}
@@ -1330,8 +1357,8 @@ BOOL LLSpatialGroup::needsUpdate()
BOOL LLSpatialGroup::changeLOD()
{
- if (isState(ALPHA_DIRTY))
- { ///an alpha sort is going to happen, update distance and LOD
+ if (isState(ALPHA_DIRTY | OBJECT_DIRTY))
+ { ///a rebuild is going to happen, update distance and LoD
return TRUE;
}
@@ -1344,7 +1371,7 @@ BOOL LLSpatialGroup::changeLOD()
return TRUE;
}
- if (mDistance > mRadius)
+ if (mDistance > mRadius*2.f)
{
return FALSE;
}
@@ -1540,15 +1567,31 @@ void LLSpatialGroup::checkOcclusion()
{ //otherwise, if a query is pending, read it back
GLuint available = 0;
- glGetQueryObjectuivARB(mOcclusionQuery[LLViewerCamera::sCurCameraID], GL_QUERY_RESULT_AVAILABLE_ARB, &available);
+ if (mOcclusionQuery[LLViewerCamera::sCurCameraID])
+ {
+ glGetQueryObjectuivARB(mOcclusionQuery[LLViewerCamera::sCurCameraID], GL_QUERY_RESULT_AVAILABLE_ARB, &available);
+ }
+ else
+ {
+ available = 1;
+ }
+
if (available)
{ //result is available, read it back, otherwise wait until next frame
GLuint res = 1;
if (!isOcclusionState(DISCARD_QUERY) && mOcclusionQuery[LLViewerCamera::sCurCameraID])
{
glGetQueryObjectuivARB(mOcclusionQuery[LLViewerCamera::sCurCameraID], GL_QUERY_RESULT_ARB, &res);
+#if LL_TRACK_PENDING_OCCLUSION_QUERIES
+ sPendingQueries.erase(mOcclusionQuery[LLViewerCamera::sCurCameraID]);
+#endif
}
-
+ else if (mOcclusionQuery[LLViewerCamera::sCurCameraID])
+ { //delete the query to avoid holding onto hundreds of pending queries
+ sQueryPool.release(mOcclusionQuery[LLViewerCamera::sCurCameraID]);
+ mOcclusionQuery[LLViewerCamera::sCurCameraID] = 0;
+ }
+
if (isOcclusionState(DISCARD_QUERY))
{
res = 2;
@@ -1621,6 +1664,13 @@ void LLSpatialGroup::doOcclusion(LLCamera* camera)
}
#if !LL_DARWIN
U32 mode = gGLManager.mHasOcclusionQuery2 ? GL_ANY_SAMPLES_PASSED : GL_SAMPLES_PASSED_ARB;
+#else
+ U32 mode = GL_SAMPLES_PASSED_ARB;
+#endif
+
+#if LL_TRACK_PENDING_OCCLUSION_QUERIES
+ sPendingQueries.insert(mOcclusionQuery[LLViewerCamera::sCurCameraID]);
+#endif
glBeginQueryARB(mode, mOcclusionQuery[LLViewerCamera::sCurCameraID]);
@@ -1637,7 +1687,7 @@ void LLSpatialGroup::doOcclusion(LLCamera* camera)
}
glEndQueryARB(mode);
-#endif
+
if (use_depth_clamp)
{
glDisable(GL_DEPTH_CLAMP);
@@ -3580,6 +3630,8 @@ void renderRaycast(LLDrawable* drawablep)
if (volume)
{
+ LLVector3 trans = drawablep->getRegion()->getOriginAgent();
+
for (S32 i = 0; i < volume->getNumVolumeFaces(); ++i)
{
const LLVolumeFace& face = volume->getVolumeFace(i);
@@ -3589,6 +3641,7 @@ void renderRaycast(LLDrawable* drawablep)
}
gGL.pushMatrix();
+ glTranslatef(trans.mV[0], trans.mV[1], trans.mV[2]);
glMultMatrixf((F32*) vobj->getRelativeXform().mMatrix);
LLVector3 start, end;
@@ -3613,7 +3666,7 @@ void renderRaycast(LLDrawable* drawablep)
LLRenderOctreeRaycast render(starta, dir, &t);
gGL.flush();
- glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
+ glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
{
//render face positions
@@ -3672,7 +3725,7 @@ void renderRaycast(LLDrawable* drawablep)
LLGLDepthTest depth(GL_FALSE, GL_TRUE);
gGL.color4f(0,0.5f,0.5f,1);
- drawBoxOutline(pos, size);
+ drawBoxOutline(pos, size);
}
}
}
@@ -4048,7 +4101,7 @@ void LLSpatialPartition::renderDebug()
LLPipeline::RENDER_DEBUG_RAYCAST |
LLPipeline::RENDER_DEBUG_AVATAR_VOLUME |
LLPipeline::RENDER_DEBUG_AGENT_TARGET |
- LLPipeline::RENDER_DEBUG_BUILD_QUEUE |
+ //LLPipeline::RENDER_DEBUG_BUILD_QUEUE |
LLPipeline::RENDER_DEBUG_SHADOW_FRUSTA))
{
return;
@@ -4088,7 +4141,7 @@ void LLSpatialGroup::drawObjectBox(LLColor4 col)
{
gGL.color4fv(col.mV);
LLVector4a size;
- size = mObjectBounds[0];
+ size = mObjectBounds[1];
size.mul(1.01f);
size.add(LLVector4a(0.001f));
drawBox(mObjectBounds[0], size);
diff --git a/indra/newview/llspatialpartition.h b/indra/newview/llspatialpartition.h
index 85fd66b297..664d957e49 100644
--- a/indra/newview/llspatialpartition.h
+++ b/indra/newview/llspatialpartition.h
@@ -187,6 +187,7 @@ public:
return *this;
}
+ static std::set<GLuint> sPendingQueries; //pending occlusion queries
static U32 sNodeCount;
static BOOL sNoDelete; //deletion of spatial groups and draw info not allowed if TRUE
diff --git a/indra/newview/llviewercontrol.cpp b/indra/newview/llviewercontrol.cpp
index 9bf0ae7c3e..414036c597 100644
--- a/indra/newview/llviewercontrol.cpp
+++ b/indra/newview/llviewercontrol.cpp
@@ -372,6 +372,12 @@ static bool handleRenderDynamicLODChanged(const LLSD& newvalue)
return true;
}
+static bool handleRenderLocalLightsChanged(const LLSD& newvalue)
+{
+ gPipeline.setLightingDetail(-1);
+ return true;
+}
+
static bool handleRenderDeferredChanged(const LLSD& newvalue)
{
LLRenderTarget::sUseFBO = newvalue.asBoolean();
@@ -592,6 +598,7 @@ void settings_setup_listeners()
gSavedSettings.getControl("RenderFogRatio")->getSignal()->connect(boost::bind(&handleFogRatioChanged, _2));
gSavedSettings.getControl("RenderMaxPartCount")->getSignal()->connect(boost::bind(&handleMaxPartCountChanged, _2));
gSavedSettings.getControl("RenderDynamicLOD")->getSignal()->connect(boost::bind(&handleRenderDynamicLODChanged, _2));
+ gSavedSettings.getControl("RenderLocalLights")->getSignal()->connect(boost::bind(&handleRenderLocalLightsChanged, _2));
gSavedSettings.getControl("RenderDebugTextureBind")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
gSavedSettings.getControl("RenderAutoMaskAlphaDeferred")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
gSavedSettings.getControl("RenderAutoMaskAlphaNonDeferred")->getSignal()->connect(boost::bind(&handleResetVertexBuffersChanged, _2));
diff --git a/indra/newview/llviewermenu.cpp b/indra/newview/llviewermenu.cpp
index a152ab4aa0..e9e0268587 100644
--- a/indra/newview/llviewermenu.cpp
+++ b/indra/newview/llviewermenu.cpp
@@ -937,6 +937,10 @@ U32 info_display_from_string(std::string info_display)
{
return LLPipeline::RENDER_DEBUG_FACE_AREA;
}
+ else if ("build queue" == info_display)
+ {
+ return LLPipeline::RENDER_DEBUG_BUILD_QUEUE;
+ }
else if ("lights" == info_display)
{
return LLPipeline::RENDER_DEBUG_LIGHTS;
diff --git a/indra/newview/llviewermenufile.cpp b/indra/newview/llviewermenufile.cpp
index 4ba1d007fe..9ecb11d253 100644
--- a/indra/newview/llviewermenufile.cpp
+++ b/indra/newview/llviewermenufile.cpp
@@ -53,6 +53,7 @@
#include "llvfs.h"
#include "llviewerinventory.h"
#include "llviewermenu.h" // gMenuHolder
+#include "llviewerparcelmgr.h"
#include "llviewerregion.h"
#include "llviewerstats.h"
#include "llviewerwindow.h"
@@ -102,6 +103,16 @@ class LLMeshEnabled : public view_listener_t
}
};
+class LLMeshUploadVisible : public view_listener_t
+{
+ bool handleEvent(const LLSD& userdata)
+ {
+ return gSavedSettings.getBOOL("MeshEnabled") &&
+ LLViewerParcelMgr::getInstance()->allowAgentBuild() &&
+ !gAgent.getRegion()->getCapability("ObjectAdd").empty();
+ }
+};
+
LLMutex* LLFilePickerThread::sMutex = NULL;
std::queue<LLFilePickerThread*> LLFilePickerThread::sDeadQ;
@@ -1390,6 +1401,7 @@ void init_menu_file()
view_listener_t::addEnable(new LLFileEnableUpload(), "File.EnableUpload");
view_listener_t::addEnable(new LLFileEnableUploadModel(), "File.EnableUploadModel");
view_listener_t::addMenu(new LLMeshEnabled(), "File.MeshEnabled");
+ view_listener_t::addMenu(new LLMeshUploadVisible(), "File.VisibleUploadModel");
// "File.SaveTexture" moved to llpanelmaininventory so that it can be properly handled.
}
diff --git a/indra/newview/llviewerwindow.cpp b/indra/newview/llviewerwindow.cpp
index dcfac012f6..db48b769e4 100644
--- a/indra/newview/llviewerwindow.cpp
+++ b/indra/newview/llviewerwindow.cpp
@@ -497,6 +497,12 @@ public:
ypos += y_inc;
+ if (!LLSpatialGroup::sPendingQueries.empty())
+ {
+ addText(xpos,ypos, llformat("%d Queries pending", LLSpatialGroup::sPendingQueries.size()));
+ ypos += y_inc;
+ }
+
addText(xpos,ypos, llformat("%d Avatars visible", LLVOAvatar::sNumVisibleAvatars));
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index feb6db4700..dd6f7011a1 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -63,6 +63,7 @@
#include "llkeyframefallmotion.h"
#include "llkeyframestandmotion.h"
#include "llkeyframewalkmotion.h"
+#include "llmanipscale.h" // for get_default_max_prim_scale()
#include "llmeshrepository.h"
#include "llmutelist.h"
#include "llmoveview.h"
@@ -1383,7 +1384,7 @@ void LLVOAvatar::getSpatialExtents(LLVector4a& newMin, LLVector4a& newMax)
newMin.setSub(pos, buffer);
newMax.setAdd(pos, buffer);
- float max_attachment_span = DEFAULT_MAX_PRIM_SCALE * 5.0f;
+ float max_attachment_span = get_default_max_prim_scale() * 5.0f;
//stretch bounding box by joint positions
for (polymesh_map_t::iterator i = mMeshes.begin(); i != mMeshes.end(); ++i)
@@ -8163,12 +8164,16 @@ BOOL LLVOAvatar::updateLOD()
mNeedsSkin = TRUE;
mDrawable->clearState(LLDrawable::REBUILD_GEOMETRY);
}
-
updateVisibility();
return res;
}
+void LLVOAvatar::updateLODRiggedAttachments( void )
+{
+ updateLOD();
+ rebuildRiggedAttachments();
+}
U32 LLVOAvatar::getPartitionType() const
{
// Avatars merely exist as drawables in the bridge partition
diff --git a/indra/newview/llvoavatar.h b/indra/newview/llvoavatar.h
index 7ef35178ca..99d0ed76e5 100644
--- a/indra/newview/llvoavatar.h
+++ b/indra/newview/llvoavatar.h
@@ -122,6 +122,7 @@ public:
virtual BOOL idleUpdate(LLAgent &agent, LLWorld &world, const F64 &time);
virtual BOOL updateLOD();
BOOL updateJointLODs();
+ void updateLODRiggedAttachments( void );
virtual BOOL isActive() const; // Whether this object needs to do an idleUpdate.
virtual void updateTextures();
virtual S32 setTETexture(const U8 te, const LLUUID& uuid); // If setting a baked texture, need to request it from a non-local sim.
diff --git a/indra/newview/llvoavatarself.cpp b/indra/newview/llvoavatarself.cpp
index 3c66c4860e..75966a0f96 100644
--- a/indra/newview/llvoavatarself.cpp
+++ b/indra/newview/llvoavatarself.cpp
@@ -625,7 +625,7 @@ BOOL LLVOAvatarSelf::updateCharacter(LLAgent &agent)
mScreenp->updateWorldMatrixChildren();
resetHUDAttachments();
}
- LLVOAvatar::rebuildRiggedAttachments();
+
return LLVOAvatar::updateCharacter(agent);
}
@@ -1139,6 +1139,7 @@ const LLViewerJointAttachment *LLVOAvatarSelf::attachObject(LLViewerObject *view
LLAppearanceMgr::instance().registerAttachment(attachment_id);
// Clear any pending requests once the attachment arrives.
removeAttachmentRequest(attachment_id);
+ updateLODRiggedAttachments();
}
return attachment;
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index 5277e073a3..b296d21b2b 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -936,6 +936,7 @@ BOOL LLVOVolume::setVolume(const LLVolumeParams &params_in, const S32 detail, bo
{
LLVolumeParams volume_params = params_in;
+ S32 last_lod = mVolumep.notNull() ? LLVolumeLODGroup::getVolumeDetailFromScale(mVolumep->getDetail()) : -1;
S32 lod = mLOD;
BOOL is404 = FALSE;
@@ -1014,7 +1015,7 @@ BOOL LLVOVolume::setVolume(const LLVolumeParams &params_in, const S32 detail, bo
{
//load request not yet issued, request pipeline load this mesh
LLUUID asset_id = volume_params.getSculptID();
- S32 available_lod = gMeshRepo.loadMesh(this, volume_params, lod);
+ S32 available_lod = gMeshRepo.loadMesh(this, volume_params, lod, last_lod);
if (available_lod != lod)
{
LLPrimitive::setVolume(volume_params, available_lod);
@@ -1075,7 +1076,6 @@ void LLVOVolume::notifyMeshLoaded()
{
mSculptChanged = TRUE;
gPipeline.markRebuild(mDrawable, LLDrawable::REBUILD_GEOMETRY, TRUE);
- dirtySpatialGroup(TRUE);
}
// sculpt replaces generate() for sculpted surfaces
@@ -1228,7 +1228,7 @@ BOOL LLVOVolume::updateLOD()
mLODChanged = TRUE;
}
- lod_changed |= LLViewerObject::updateLOD();
+ lod_changed = lod_changed || LLViewerObject::updateLOD();
return lod_changed;
}
@@ -1608,6 +1608,17 @@ BOOL LLVOVolume::updateGeometry(LLDrawable *drawable)
regenFaces();
}
genBBoxes(FALSE);
+
+ if (mSculptChanged)
+ { //changes in sculpt maps can thrash an object bounding box without
+ //triggering a spatial group bounding box update -- force spatial group
+ //to update bounding boxes
+ LLSpatialGroup* group = mDrawable->getSpatialGroup();
+ if (group)
+ {
+ group->unbound();
+ }
+ }
}
}
}
@@ -1632,7 +1643,7 @@ BOOL LLVOVolume::updateGeometry(LLDrawable *drawable)
mLODChanged = FALSE;
mSculptChanged = FALSE;
mFaceMappingChanged = FALSE;
-
+
return LLViewerObject::updateGeometry(drawable);
}
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index 38711472a1..510d22136b 100755
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -330,6 +330,8 @@ LLPipeline::LLPipeline() :
mRenderDebugFeatureMask(0),
mRenderDebugMask(0),
mOldRenderDebugMask(0),
+ mGroupQ1Locked(false),
+ mGroupQ2Locked(false),
mLastRebuildPool(NULL),
mAlphaPool(NULL),
mSkyPool(NULL),
@@ -2118,6 +2120,7 @@ void LLPipeline::rebuildPriorityGroups()
gMeshRepo.notifyLoadedMeshes();
+ mGroupQ1Locked = true;
// Iterate through all drawables on the priority build queue,
for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ1.begin();
iter != mGroupQ1.end(); ++iter)
@@ -2128,11 +2131,18 @@ void LLPipeline::rebuildPriorityGroups()
}
mGroupQ1.clear();
+ mGroupQ1Locked = false;
}
void LLPipeline::rebuildGroups()
{
+ if (mGroupQ2.empty())
+ {
+ return;
+ }
+
+ mGroupQ2Locked = true;
// Iterate through some drawables on the non-priority build queue
S32 size = (S32) mGroupQ2.size();
S32 min_count = llclamp((S32) ((F32) (size * size)/4096*0.25f), 1, size);
@@ -2142,33 +2152,30 @@ void LLPipeline::rebuildGroups()
std::sort(mGroupQ2.begin(), mGroupQ2.end(), LLSpatialGroup::CompareUpdateUrgency());
LLSpatialGroup::sg_vector_t::iterator iter;
+ LLSpatialGroup::sg_vector_t::iterator last_iter = mGroupQ2.begin();
+
for (iter = mGroupQ2.begin();
- iter != mGroupQ2.end(); ++iter)
+ iter != mGroupQ2.end() && count <= min_count; ++iter)
{
LLSpatialGroup* group = *iter;
+ last_iter = iter;
- if (group->isDead())
+ if (!group->isDead())
{
- continue;
+ group->rebuildGeom();
+
+ if (group->mSpatialPartition->mRenderByGroup)
+ {
+ count++;
+ }
}
- group->rebuildGeom();
-
- if (group->mSpatialPartition->mRenderByGroup)
- {
- count++;
- }
-
group->clearState(LLSpatialGroup::IN_BUILD_Q2);
-
- if (count > min_count)
- {
- ++iter;
- break;
- }
}
- mGroupQ2.erase(mGroupQ2.begin(), iter);
+ mGroupQ2.erase(mGroupQ2.begin(), ++last_iter);
+
+ mGroupQ2Locked = false;
updateMovedList(mMovedBridge);
}
@@ -2463,6 +2470,8 @@ void LLPipeline::markRebuild(LLSpatialGroup* group, BOOL priority)
{
if (!group->isState(LLSpatialGroup::IN_BUILD_Q1))
{
+ llassert_always(!mGroupQ1Locked);
+
mGroupQ1.push_back(group);
group->setState(LLSpatialGroup::IN_BUILD_Q1);
@@ -2479,11 +2488,7 @@ void LLPipeline::markRebuild(LLSpatialGroup* group, BOOL priority)
}
else if (!group->isState(LLSpatialGroup::IN_BUILD_Q2 | LLSpatialGroup::IN_BUILD_Q1))
{
- //llerrs << "Non-priority updates not yet supported!" << llendl;
- if (std::find(mGroupQ2.begin(), mGroupQ2.end(), group) != mGroupQ2.end())
- {
- llerrs << "WTF?" << llendl;
- }
+ llassert_always(!mGroupQ2Locked);
mGroupQ2.push_back(group);
group->setState(LLSpatialGroup::IN_BUILD_Q2);
@@ -2563,6 +2568,42 @@ void LLPipeline::stateSort(LLCamera& camera, LLCullResult &result)
}
}
}
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ {
+ LLSpatialGroup* last_group = NULL;
+ for (LLCullResult::bridge_list_t::iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i)
+ {
+ LLCullResult::bridge_list_t::iterator cur_iter = i;
+ LLSpatialBridge* bridge = *cur_iter;
+ LLSpatialGroup* group = bridge->getSpatialGroup();
+
+ if (last_group == NULL)
+ {
+ last_group = group;
+ }
+
+ if (!bridge->isDead() && group && !group->isOcclusionState(LLSpatialGroup::OCCLUDED))
+ {
+ stateSort(bridge, camera);
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD &&
+ last_group != group && last_group->changeLOD())
+ {
+ last_group->mLastUpdateDistance = last_group->mDistance;
+ }
+
+ last_group = group;
+ }
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD &&
+ last_group && last_group->changeLOD())
+ {
+ last_group->mLastUpdateDistance = last_group->mDistance;
+ }
+ }
+
for (LLCullResult::sg_list_t::iterator iter = sCull->beginVisibleGroups(); iter != sCull->endVisibleGroups(); ++iter)
{
LLSpatialGroup* group = *iter;
@@ -2578,19 +2619,6 @@ void LLPipeline::stateSort(LLCamera& camera, LLCullResult &result)
}
}
- if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
- {
- for (LLCullResult::bridge_list_t::iterator i = sCull->beginVisibleBridge(); i != sCull->endVisibleBridge(); ++i)
- {
- LLCullResult::bridge_list_t::iterator cur_iter = i;
- LLSpatialBridge* bridge = *cur_iter;
- LLSpatialGroup* group = bridge->getSpatialGroup();
- if (!bridge->isDead() && group && !group->isOcclusionState(LLSpatialGroup::OCCLUDED))
- {
- stateSort(bridge, camera);
- }
- }
- }
{
LLFastTimer ftm(FTM_STATESORT_DRAWABLE);
for (LLCullResult::drawable_list_t::iterator iter = sCull->beginVisibleList();
@@ -2621,6 +2649,11 @@ void LLPipeline::stateSort(LLSpatialGroup* group, LLCamera& camera)
LLDrawable* drawablep = *i;
stateSort(drawablep, camera);
}
+
+ if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
+ { //avoid redundant stateSort calls
+ group->mLastUpdateDistance = group->mDistance;
+ }
}
}
@@ -2687,21 +2720,17 @@ void LLPipeline::stateSort(LLDrawable* drawablep, LLCamera& camera)
if (LLViewerCamera::sCurCameraID == LLViewerCamera::CAMERA_WORLD)
{
- LLSpatialGroup* group = drawablep->getSpatialGroup();
- if (!group || group->changeLOD())
+ if (drawablep->isVisible())
{
- if (drawablep->isVisible())
+ if (!drawablep->isActive())
{
- if (!drawablep->isActive())
- {
- bool force_update = false;
- drawablep->updateDistance(camera, force_update);
- }
- else if (drawablep->isAvatar())
- {
- bool force_update = false;
- drawablep->updateDistance(camera, force_update); // calls vobj->updateLOD() which calls LLVOAvatar::updateVisibility()
- }
+ bool force_update = false;
+ drawablep->updateDistance(camera, force_update);
+ }
+ else if (drawablep->isAvatar())
+ {
+ bool force_update = false;
+ drawablep->updateDistance(camera, force_update); // calls vobj->updateLOD() which calls LLVOAvatar::updateVisibility()
}
}
}
@@ -4191,13 +4220,19 @@ void LLPipeline::renderDebug()
if (mRenderDebugMask & LLPipeline::RENDER_DEBUG_BUILD_QUEUE)
{
U32 count = 0;
- U32 size = mBuildQ2.size();
+ U32 size = mGroupQ2.size();
LLColor4 col;
+ LLVertexBuffer::unbind();
LLGLEnable blend(GL_BLEND);
+ gGL.setSceneBlendType(LLRender::BT_ALPHA);
LLGLDepthTest depth(GL_TRUE, GL_FALSE);
gGL.getTexUnit(0)->bind(LLViewerFetchedTexture::sWhiteImagep);
+ gGL.pushMatrix();
+ glLoadMatrixd(gGLModelView);
+ gGLLastMatrix = NULL;
+
for (LLSpatialGroup::sg_vector_t::iterator iter = mGroupQ2.begin(); iter != mGroupQ2.end(); ++iter)
{
LLSpatialGroup* group = *iter;
@@ -4219,7 +4254,7 @@ void LLPipeline::renderDebug()
glMultMatrixf((F32*)bridge->mDrawable->getRenderMatrix().mMatrix);
}
- F32 alpha = (F32) (size-count)/size;
+ F32 alpha = llclamp((F32) (size-count)/size, 0.f, 1.f);
LLVector2 c(1.f-alpha, alpha);
@@ -4227,7 +4262,7 @@ void LLPipeline::renderDebug()
++count;
- col.set(c.mV[0], c.mV[1], 0, alpha*0.5f+0.1f);
+ col.set(c.mV[0], c.mV[1], 0, alpha*0.5f+0.5f);
group->drawObjectBox(col);
if (bridge)
@@ -4237,6 +4272,7 @@ void LLPipeline::renderDebug()
}
}
+ gGL.popMatrix();
gGL.flush();
gPipeline.renderPhysicsDisplay();
diff --git a/indra/newview/pipeline.h b/indra/newview/pipeline.h
index 7ae83e9816..0eb020605e 100644
--- a/indra/newview/pipeline.h
+++ b/indra/newview/pipeline.h
@@ -632,6 +632,8 @@ protected:
LLDrawable::drawable_list_t mBuildQ2; // non-priority
LLSpatialGroup::sg_vector_t mGroupQ1; //priority
LLSpatialGroup::sg_vector_t mGroupQ2; // non-priority
+ bool mGroupQ2Locked;
+ bool mGroupQ1Locked;
LLViewerObject::vobj_list_t mCreateQ;
diff --git a/indra/newview/skins/default/xui/en/menu_inventory_add.xml b/indra/newview/skins/default/xui/en/menu_inventory_add.xml
index e0e6567872..62db15d456 100644
--- a/indra/newview/skins/default/xui/en/menu_inventory_add.xml
+++ b/indra/newview/skins/default/xui/en/menu_inventory_add.xml
@@ -52,7 +52,7 @@
<menu_item_call.on_enable
function="File.EnableUploadModel" />
<menu_item_call.on_visible
- function="File.MeshEnabled"/>
+ function="File.VisibleUploadModel"/>
</menu_item_call>
<menu_item_call
label="Bulk (L$[COST] per file)..."
diff --git a/indra/newview/skins/default/xui/en/menu_viewer.xml b/indra/newview/skins/default/xui/en/menu_viewer.xml
index cb2cbbe033..3e006d7b31 100644
--- a/indra/newview/skins/default/xui/en/menu_viewer.xml
+++ b/indra/newview/skins/default/xui/en/menu_viewer.xml
@@ -970,7 +970,7 @@
<menu_item_call.on_enable
function="File.EnableUploadModel" />
<menu_item_call.on_visible
- function="File.MeshEnabled"/>
+ function="File.VisibleUploadModel"/>
</menu_item_call>
<menu_item_call
label="Model Wizard..."
@@ -982,7 +982,7 @@
<menu_item_call.on_enable
function="File.EnableUploadModel" />
<menu_item_call.on_visible
- function="File.MeshEnabled"/>
+ function="File.VisibleUploadModel"/>
</menu_item_call>
<menu_item_call
label="Bulk (L$[COST] per file)..."
@@ -2258,6 +2258,16 @@
parameter="face area" />
</menu_item_check>
<menu_item_check
+ label="Build Queue"
+ name="Build Queue">
+ <menu_item_check.on_check
+ function="Advanced.CheckInfoDisplay"
+ parameter="build queue" />
+ <menu_item_check.on_click
+ function="Advanced.ToggleInfoDisplay"
+ parameter="build queue" />
+ </menu_item_check>
+ <menu_item_check
label="Lights"
name="Lights">
<menu_item_check.on_check
diff --git a/indra/newview/skins/default/xui/en/notifications.xml b/indra/newview/skins/default/xui/en/notifications.xml
index 4fbe7b564f..de13379099 100644
--- a/indra/newview/skins/default/xui/en/notifications.xml
+++ b/indra/newview/skins/default/xui/en/notifications.xml
@@ -6737,6 +6737,12 @@ The site at &apos;&lt;nolink&gt;[HOST_NAME]&lt;/nolink&gt;&apos; in realm &apos;
- Your CPU speed does not meet the minimum requirements.
</global>
+ <global name="UnsupportedCPUSSE2">
+Your CPU does not seem to have the required support for SSE2 operations.
+
+Please see http://www.secondlife.com/corporate/sysreqs.php for information about system requirements.
+ </global>
+
<global name="UnsupportedGLRequirements">
You do not appear to have the proper hardware requirements for [APP_NAME]. [APP_NAME] requires an OpenGL graphics card that has multitexture support. If this is the case, you may want to make sure that you have the latest drivers for your graphics card, and service packs and patches for your operating system.