summaryrefslogtreecommitdiff
path: root/indra/newview
diff options
context:
space:
mode:
Diffstat (limited to 'indra/newview')
-rw-r--r--indra/newview/app_settings/logcontrol.xml2
-rw-r--r--indra/newview/llcontrolavatar.cpp9
-rw-r--r--indra/newview/llpanelobject.cpp11
-rw-r--r--indra/newview/llviewermessage.cpp14
-rw-r--r--indra/newview/llvoavatar.cpp17
-rw-r--r--indra/newview/llvovolume.cpp56
-rw-r--r--indra/newview/pipeline.cpp4
7 files changed, 62 insertions, 51 deletions
diff --git a/indra/newview/app_settings/logcontrol.xml b/indra/newview/app_settings/logcontrol.xml
index 5329b76390..ae57e125bb 100644
--- a/indra/newview/app_settings/logcontrol.xml
+++ b/indra/newview/app_settings/logcontrol.xml
@@ -51,7 +51,7 @@
<key>tags</key>
<array>
<!-- sample entry for debugging specific items
- <string>AXON</string>
+ <string>AnimatedObjects</string>
<string>Avatar</string>
<string>Inventory</string>
<string>SceneLoadTiming</string>
diff --git a/indra/newview/llcontrolavatar.cpp b/indra/newview/llcontrolavatar.cpp
index 7e89a97c03..920b0fa151 100644
--- a/indra/newview/llcontrolavatar.cpp
+++ b/indra/newview/llcontrolavatar.cpp
@@ -52,7 +52,7 @@ LLControlAvatar::~LLControlAvatar()
// virtual
void LLControlAvatar::initInstance()
{
- // AXON - potential optimizations here: avoid creating system
+ // Potential optimizations here: avoid creating system
// avatar mesh content since it's not used. For now we just clean some
// things up after the fact in releaseMeshData().
LLVOAvatar::initInstance();
@@ -280,10 +280,11 @@ void LLControlAvatar::updateDebugText()
type_string += "-";
}
}
- addDebugText(llformat("CAV obj %d anim %d active %s",
- total_linkset_count, animated_volume_count, active_string.c_str()));
+ addDebugText(llformat("CAV obj %d anim %d active %s impost %d",
+ total_linkset_count, animated_volume_count, active_string.c_str(), (S32) isImpostor()));
addDebugText(llformat("types %s lods %s", type_string.c_str(), lod_string.c_str()));
addDebugText(llformat("tris %d verts %d", total_tris, total_verts));
+ addDebugText(llformat("pxarea %s", LLStringOps::getReadableNumber(getPixelArea()).c_str()));
std::string region_name = "no region";
if (mRootVolp->getRegion())
{
@@ -335,7 +336,7 @@ void LLControlAvatar::updateAnimations()
{
if (!mRootVolp)
{
- LL_WARNS_ONCE("AXON") << "No root vol" << LL_ENDL;
+ LL_WARNS_ONCE("AnimatedObjects") << "No root vol" << LL_ENDL;
return;
}
diff --git a/indra/newview/llpanelobject.cpp b/indra/newview/llpanelobject.cpp
index 8f2cf5bb89..cd00a6f98f 100644
--- a/indra/newview/llpanelobject.cpp
+++ b/indra/newview/llpanelobject.cpp
@@ -347,9 +347,14 @@ void LLPanelObject::getState( )
// it's not entirely clear what the motivation is to have 3
// different rules for enablement. At least the difference between
// move and rotate looks like just a parens error, have updated accordingly.
- BOOL enable_move = objectp->permMove() && !objectp->isPermanentEnforced() && ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) && ((objectp->permModify() && !objectp->isAttachment()) || !gSavedSettings.getBOOL("EditLinkedParts"));
- BOOL enable_scale = objectp->permMove() && !objectp->isPermanentEnforced() && ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) && objectp->permModify();
- BOOL enable_rotate = objectp->permMove() && !objectp->isPermanentEnforced() && ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) && ((objectp->permModify() && !objectp->isAttachment()) || !gSavedSettings.getBOOL("EditLinkedParts"));
+ BOOL enable_move = objectp->permMove() && !objectp->isPermanentEnforced() &&
+ ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) &&
+ ((objectp->permModify() && !objectp->isAttachment()) || !gSavedSettings.getBOOL("EditLinkedParts"));
+ BOOL enable_scale = objectp->permMove() && !objectp->isPermanentEnforced() &&
+ ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) && objectp->permModify();
+ BOOL enable_rotate = objectp->permMove() && !objectp->isPermanentEnforced() &&
+ ((root_objectp == NULL) || !root_objectp->isPermanentEnforced()) &&
+ ((objectp->permModify() && !objectp->isAttachment()) || !gSavedSettings.getBOOL("EditLinkedParts"));
S32 selected_count = LLSelectMgr::getInstance()->getSelection()->getObjectCount();
BOOL single_volume = (LLSelectMgr::getInstance()->selectionAllPCode( LL_PCODE_VOLUME ))
diff --git a/indra/newview/llviewermessage.cpp b/indra/newview/llviewermessage.cpp
index 24af491391..bfaad30fc1 100644
--- a/indra/newview/llviewermessage.cpp
+++ b/indra/newview/llviewermessage.cpp
@@ -5086,32 +5086,32 @@ void process_object_animation(LLMessageSystem *mesgsys, void **user_data)
LLViewerObject *objp = gObjectList.findObject(uuid);
if (!objp)
{
- LL_WARNS("Messaging") << "AXON Received animation state for unknown object" << uuid << LL_ENDL;
+ LL_WARNS("Messaging") << "Received animation state for unknown object" << uuid << LL_ENDL;
return;
}
LLVOVolume *volp = dynamic_cast<LLVOVolume*>(objp);
if (!volp)
{
- LL_WARNS("Messaging") << "AXON Received animation state for non-volume object" << uuid << LL_ENDL;
+ LL_WARNS("Messaging") << "Received animation state for non-volume object" << uuid << LL_ENDL;
return;
}
if (!volp->isAnimatedObject())
{
- LL_WARNS("Messaging") << "AXON Received animation state for non-animated object" << uuid << LL_ENDL;
+ LL_WARNS("Messaging") << "Received animation state for non-animated object" << uuid << LL_ENDL;
return;
}
LLControlAvatar *avatarp = volp->getControlAvatar();
if (!avatarp)
{
- LL_WARNS("Messaging") << "AXON no control avatar, ignoring" << LL_ENDL;
+ LL_WARNS("Messaging") << "Received animation request for object with no control avatar, ignoring" << LL_ENDL;
return;
}
S32 num_blocks = mesgsys->getNumberOfBlocksFast(_PREHASH_AnimationList);
- LL_DEBUGS("AXON") << "processing object animation requests, num_blocks " << num_blocks << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << "processing object animation requests, num_blocks " << num_blocks << LL_ENDL;
#if 1
// Here we go into skinned mode once, the first time we get an
@@ -5156,8 +5156,8 @@ void process_object_animation(LLMessageSystem *mesgsys, void **user_data)
mesgsys->getUUIDFast(_PREHASH_AnimationList, _PREHASH_AnimID, animation_id, i);
mesgsys->getS32Fast(_PREHASH_AnimationList, _PREHASH_AnimSequenceID, anim_sequence_id, i);
volp->mObjectSignaledAnimations[animation_id] = anim_sequence_id;
- LL_DEBUGS("AXON") << "got object animation request for object "
- << uuid << " animation id " << animation_id << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << "got object animation request for object "
+ << uuid << " animation id " << animation_id << LL_ENDL;
}
avatarp->updateAnimations();
diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp
index bc5cca4a65..a91e9ff53d 100644
--- a/indra/newview/llvoavatar.cpp
+++ b/indra/newview/llvoavatar.cpp
@@ -3461,6 +3461,10 @@ void LLVOAvatar::updateDebugText()
LLVector3 pelvis_pos = mPelvisp->getPosition();
debug_line += llformat(" rp %.3f pp %.3f", root_pos[2], pelvis_pos[2]);
+ S32 is_visible = (S32) isVisible();
+ S32 is_m_visible = (S32) mVisible;
+ debug_line += llformat(" v %d/%d", is_visible, is_m_visible);
+
addDebugText(debug_line);
}
@@ -3681,7 +3685,7 @@ void LLVOAvatar::computeUpdatePeriod()
if (mDrawable.notNull()
&& isVisible()
&& (!isSelf() || visually_muted)
- && !mIsDummy
+ && (!mIsDummy || isControlAvatar())
&& sUseImpostors
&& !mNeedsAnimUpdate
&& !sFreezeCounter)
@@ -3900,7 +3904,7 @@ void LLVOAvatar::updateTimeStep()
bool is_pure_dummy = mIsDummy && !isControlAvatar();
if (!isSelf() && !is_pure_dummy) // ie, non-self avatars, and animated objects will be affected.
{
- // AXON note that sInstances counts animated objects and
+ // Note that sInstances counts animated objects and
// standard avatars in the same bucket. Is this desirable?
F32 time_quantum = clamp_rescale((F32)sInstances.size(), 10.f, 35.f, 0.f, 0.25f);
F32 pixel_area_scale = clamp_rescale(mPixelArea, 100, 5000, 1.f, 0.f);
@@ -6162,7 +6166,7 @@ F32 LLVOAvatar::getTimeDilation()
F32 LLVOAvatar::getPixelArea() const
{
// AXON UPDATE FOR CONTROL AVATARS
- if (mIsDummy)
+ if (mIsDummy && !isControlAvatar())
{
return 100000.f;
}
@@ -7138,9 +7142,14 @@ void LLVOAvatar::onGlobalColorChanged(const LLTexGlobalColor* global_color)
updateMeshTextures();
}
+// FIXME: We have an mVisible member, set in updateVisibility(), but this
+// function doesn't return it! isVisible() and mVisible are used
+// different places for different purposes. mVisible seems to be more
+// related to whether the actual avatar mesh is shown, and isVisible()
+// to whether anything about the avatar is displayed in the scene.
+// Maybe better naming could make this clearer?
BOOL LLVOAvatar::isVisible() const
{
- // AXON should we flag control avs as invisible?
return mDrawable.notNull()
&& (!mOrphaned || isSelf())
&& (mDrawable->isVisible() || mIsDummy);
diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp
index fbbf0634ff..8c722bf106 100644
--- a/indra/newview/llvovolume.cpp
+++ b/indra/newview/llvovolume.cpp
@@ -1354,7 +1354,7 @@ BOOL LLVOVolume::updateLOD()
{
std::string vobj_name = llformat("Vol%u", (U32) this);
F32 est_tris = getEstTrianglesMax();
- LL_DEBUGS("AXONLinkset") << vobj_name << " updateLOD to " << getLOD() << ", tris " << est_tris << LL_ENDL;
+ LL_DEBUGS("AnimatedObjectsLinkset") << vobj_name << " updateLOD to " << getLOD() << ", tris " << est_tris << LL_ENDL;
}
#endif
gPipeline.markRebuild(mDrawable, LLDrawable::REBUILD_VOLUME, FALSE);
@@ -3396,10 +3396,10 @@ void LLVOVolume::setExtendedMeshFlags(U32 flags)
param_block->setFlags(flags);
}
parameterChanged(LLNetworkData::PARAMS_EXTENDED_MESH, true);
- LL_DEBUGS("AXON") << (U32) this
- << " new flags " << flags << " curr_flags " << curr_flags
- << ", calling onSetExtendedMeshFlags()"
- << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << (U32) this
+ << " new flags " << flags << " curr_flags " << curr_flags
+ << ", calling onSetExtendedMeshFlags()"
+ << LL_ENDL;
onSetExtendedMeshFlags(flags);
}
}
@@ -3440,13 +3440,12 @@ void LLVOVolume::updateAnimatedObjectStateOnReparent(LLViewerObject *old_parent,
{
LLVOVolume *old_volp = dynamic_cast<LLVOVolume*>(old_parent);
- // AXON - depending on whether animated objects can be attached,
- // we may want to include or remove the isAvatar() check.
- // BUG??
if (new_parent && !new_parent->isAvatar())
{
if (mControlAvatar.notNull())
{
+ // Here an animated object is being made the child of some
+ // other prim. Should remove the control av from the child.
LLControlAvatar *av = mControlAvatar;
mControlAvatar = NULL;
av->markForDeath();
@@ -3925,17 +3924,14 @@ void LLVOVolume::parameterChanged(U16 param_type, LLNetworkData* data, BOOL in_u
{
U32 extended_mesh_flags = getExtendedMeshFlags();
bool enabled = (extended_mesh_flags & LLExtendedMeshParams::ANIMATED_MESH_ENABLED_FLAG);
- // AXON This is kind of a guess. Better if we could compare
- // the before and after flags directly. What about cases where
- // there's no control avatar for optimization reasons?
bool was_enabled = (getControlAvatar() != NULL);
if (enabled != was_enabled)
{
- LL_DEBUGS("AXON") << (U32) this
- << " calling onSetExtendedMeshFlags, enabled " << (U32) enabled
- << " was_enabled " << (U32) was_enabled
- << " local_origin " << (U32) local_origin
- << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << (U32) this
+ << " calling onSetExtendedMeshFlags, enabled " << (U32) enabled
+ << " was_enabled " << (U32) was_enabled
+ << " local_origin " << (U32) local_origin
+ << LL_ENDL;
onSetExtendedMeshFlags(extended_mesh_flags);
}
}
@@ -4080,7 +4076,7 @@ void LLVOVolume::markForUpdate(BOOL priority)
{
std::string vobj_name = llformat("Vol%u", (U32) this);
F32 est_tris = getEstTrianglesMax();
- LL_DEBUGS("AXONLinkset") << vobj_name << " markForUpdate, tris " << est_tris << LL_ENDL;
+ LL_DEBUGS("AnimatedObjectsLinkset") << vobj_name << " markForUpdate, tris " << est_tris << LL_ENDL;
}
#endif
LLViewerObject::markForUpdate(priority);
@@ -5028,15 +5024,15 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
F32 est_tris = vobj->getEstTrianglesMax();
#if 1
- LL_DEBUGS("AXONLinkset") << vobj_name << " rebuilding, isAttachment: " << (U32) vobj->isAttachment()
- << " is_mesh " << is_mesh
- << " est_tris " << est_tris
- << " is_animated " << vobj->isAnimatedObject()
- << " can_animate " << vobj->canBeAnimatedObject()
- << " cav " << vobj->getControlAvatar()
- << " playing " << (U32) (vobj->getControlAvatar() ? vobj->getControlAvatar()->mPlaying : false)
- << " frame " << LLFrameTimer::getFrameCount()
- << LL_ENDL;
+ LL_DEBUGS("AnimatedObjectsLinkset") << vobj_name << " rebuilding, isAttachment: " << (U32) vobj->isAttachment()
+ << " is_mesh " << is_mesh
+ << " est_tris " << est_tris
+ << " is_animated " << vobj->isAnimatedObject()
+ << " can_animate " << vobj->canBeAnimatedObject()
+ << " cav " << vobj->getControlAvatar()
+ << " playing " << (U32) (vobj->getControlAvatar() ? vobj->getControlAvatar()->mPlaying : false)
+ << " frame " << LLFrameTimer::getFrameCount()
+ << LL_ENDL;
#endif
llassert_always(vobj);
@@ -5059,11 +5055,11 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
F32 tri_count = vobj->getRootEdit()->recursiveGetEstTrianglesMax();
if (tri_count <= 0.f)
{
- LL_DEBUGS("AXON") << vobj_name << " not calling linkControlAvatar(), because no tris" << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << vobj_name << " not calling linkControlAvatar(), because no tris" << LL_ENDL;
}
else
{
- LL_DEBUGS("AXON") << vobj_name << " calling linkControlAvatar()" << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << vobj_name << " calling linkControlAvatar()" << LL_ENDL;
vobj->linkControlAvatar();
}
}
@@ -5079,7 +5075,7 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group)
// the checkbox has changed since the last rebuild.
if (vobj->getControlAvatar())
{
- LL_DEBUGS("AXON") << vobj_name << " calling unlinkControlAvatar()" << LL_ENDL;
+ LL_DEBUGS("AnimatedObjects") << vobj_name << " calling unlinkControlAvatar()" << LL_ENDL;
vobj->unlinkControlAvatar();
}
}
@@ -5583,7 +5579,7 @@ void LLVolumeGeometryManager::rebuildMesh(LLSpatialGroup* group)
{
std::string vobj_name = llformat("Vol%u", (U32) vobj);
F32 est_tris = vobj->getEstTrianglesMax();
- LL_DEBUGS("AXONLinkset") << vobj_name << " rebuildMesh, tris " << est_tris << LL_ENDL;
+ LL_DEBUGS("AnimatedObjectsLinkset") << vobj_name << " rebuildMesh, tris " << est_tris << LL_ENDL;
}
#endif
vobj->preRebuild();
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index 900c749ee0..6be5db8246 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -3357,8 +3357,8 @@ void LLPipeline::markRebuild(LLDrawable *drawablep, LLDrawable::EDrawableFlags f
{
std::string vobj_name = llformat("Vol%u", (U32) vol_obj);
F32 est_tris = vol_obj->getEstTrianglesMax();
- LL_DEBUGS("AXONLinkset") << vobj_name << " markRebuild, tris " << est_tris
- << " priority " << (S32) priority << " flag " << std::hex << flag << LL_ENDL;
+ LL_DEBUGS("AnimatedObjectsLinkset") << vobj_name << " markRebuild, tris " << est_tris
+ << " priority " << (S32) priority << " flag " << std::hex << flag << LL_ENDL;
}
#endif