SH-3909 Support avatar height offset

Adding a new visual param that allows users to manually adjust an offset for
how far off the ground (+ or -) their avatar's root bone is.

Supports the +-2m range people are used to adjusting in their viewers, but
new implementation should support server-generated appearances.

Conflicts:

	indra/newview/character/avatar_lad.xml
	indra/newview/llagent.cpp
	indra/newview/llcallingcard.cpp
	indra/newview/skins/default/xui/en/strings.xml
This commit is contained in:
Nyx Linden
2013-03-19 02:05:53 +01:00
committed by Latif Khalifa
parent ad03c27805
commit 07850410b5
7 changed files with 36 additions and 8 deletions

View File

@@ -465,6 +465,10 @@ void LLAvatarAppearance::computeBodySize()
LLVector3 foot = mFootLeftp->getPosition();
F32 old_offset = mAvatarOffset.mV[VZ];
mAvatarOffset.mV[VZ] = getVisualParamWeight(11001);
mPelvisToFoot = hip.mV[VZ] * pelvis_scale.mV[VZ] -
knee.mV[VZ] * hip_scale.mV[VZ] -
ankle.mV[VZ] * knee_scale.mV[VZ] -
@@ -484,7 +488,10 @@ void LLAvatarAppearance::computeBodySize()
new_body_size.mV[VX] = DEFAULT_AGENT_DEPTH;
new_body_size.mV[VY] = DEFAULT_AGENT_WIDTH;
if (new_body_size != mBodySize)
mAvatarOffset.mV[VX] = 0.0f;
mAvatarOffset.mV[VY] = 0.0f;
if (new_body_size != mBodySize || old_offset != mAvatarOffset.mV[VZ])
{
mBodySize = new_body_size;
bodySizeChanged();