From 0d4e4cb2bec301a611cf11fd4ed3edd6218f967c Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Tue, 21 Jun 2016 17:26:41 -0400 Subject: [PATCH 01/16] SL-117 - possible skeleton changes for endpoints, jaw, eyelids --- indra/newview/character/avatar_skeleton.xml | 34 ++++++++++----------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/indra/newview/character/avatar_skeleton.xml b/indra/newview/character/avatar_skeleton.xml index 9b34deeb95..7d13f4907a 100644 --- a/indra/newview/character/avatar_skeleton.xml +++ b/indra/newview/character/avatar_skeleton.xml @@ -21,10 +21,10 @@ - - - - + + + + @@ -34,10 +34,10 @@ - - - - + + + + @@ -55,14 +55,14 @@ - - - + + + - - - - + + + + @@ -179,7 +179,7 @@ - + @@ -220,7 +220,7 @@ - + From 30d17f3fd5a08936904d4123f802f6a0ee415009 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Wed, 22 Jun 2016 19:11:38 -0400 Subject: [PATCH 02/16] SL-117, SL-344 - additional proposed updates for skeleton, sliders --- indra/newview/character/avatar_lad.xml | 1115 +++++++++++-------- indra/newview/character/avatar_skeleton.xml | 6 +- 2 files changed, 656 insertions(+), 465 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 7f9dc73ddd..8b4d503eb1 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -1,6 +1,6 @@ + version="2.0" wearable_definition_version="22"> - + - + - + - - + + - + @@ -880,7 +880,7 @@ - + @@ -971,7 +971,7 @@ scale="0.0 0.0 0.0" offset="0 -0.02 0" /> - @@ -1163,7 +1163,7 @@ name="mEyeRight" scale="0 0 0" offset="0 -.009 0" /> - + - + + offset="0 .00930 0" /> - + offset="0 -.00930 0" /> + + offset="0 .00930 0" /> - + offset="0 -.00930 0" /> + + offset="0 .00930 0" /> - + offset="0 -.00930 0" /> + + offset="0 .00930 0" /> - + offset="0 -.00930 0" /> + - + - + @@ -1257,7 +1257,7 @@ name="mEyeRight" scale="0 0 0" offset="0 0 -.004" /> - + + offset="0 0 -.004" /> - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -1440,6 +1440,26 @@ name="mFaceEyeAltRight" scale="0 0 0" offset=".016 0 0" /> + + + + + + + + + + - - - - - - + offset="0.02 0 0" /> - + + - - + + - - - - - - @@ -1527,9 +1547,19 @@ offset="0.012 0 0" /> + offset="0.014 0 0" /> + + + + @@ -1623,10 +1653,10 @@ name="mFaceEyebrowOuterLeft" scale="0 0 0 " offset=".0013 0 0" /> + + - - - + @@ -1648,27 +1678,27 @@ name = "mFaceTeethLower" scale = "1 1 1" offset = "0 0 0" /> - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + + + + + - + - + + scale="0 0 0" + offset="-.005 0.0 -0.0" /> - + scale="0 0 0" + offset="-.005 0.0 -0.0" /> + + scale="0 0 0" + offset="-.005 0.0 -0.0" /> - + scale="0 0 0" + offset="-.005 0.0 -0.0" /> + - + - + @@ -2183,7 +2223,7 @@ scale="0 0 .5" /> - + - + - + - + - + @@ -2285,11 +2325,11 @@ + offset = "0.001 0.010 0"/> + offset = "-0.001 -0.01 0" /> @@ -2302,44 +2342,44 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - + + @@ -2982,14 +3022,14 @@ - + + offset = "0.0 0.005 0.0" /> - + - + - + @@ -3063,15 +3103,15 @@ - + - + - + + - - - - - - - - - + - - - - - - - - - - + + + + - + - + - - + + + name = "mFaceTeethLower" + offset = "0.005 0 0" + scale = "0.0 0.0 0.0" /> + + + + + + + + + - + - + - + - + - + - + - + - + scale = "0.0 0.5 0.0" /> + - - + + + offset="0 0 .0035" /> - + offset="0 0 .0035" /> + + offset="0 0 -.0035" /> + offset="0 0 -.0035" /> - + - + - + - + - + + offset="0 0 0" /> + offset="0 0 0" /> - + - + - + - + - + - + - + - + - + - + - + - + - + + offset="0 0 0.005" /> - + offset="0 -0.00225 0.0075" /> + - + - + - + - + - + - + + offset="0 0 0.005" /> + offset="0 0.000 0.005" /> - + - - - + scale="0 -0.07 0.07" + offset="0 0 0.005" /> + - + - + - - + + - + - + - + - + - + - + - + - + - + offset="0 -0.00225 0.0075" /> + - + - + - + - + - + - + - + - - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - + + @@ -4054,7 +4071,7 @@ name="mFaceJaw" scale="0.0 0.5 0.0" offset="0.0 0.0 0.0" /> - + - - + + - + - + - + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - - + + cross_wearable="true" + value_min="0" + value_max="1"> @@ -8754,7 +8964,7 @@ - + - + - + id="30004" /> - + - - + + id="30656" /> - + id="30506" /> - + id="30764" /> - + - + id="30035" /> - + id="30015" /> - + id="30796" /> - + id="30185" /> - + id="30760" /> - - + + id="30665" /> - + id="20006" /> - + - + id="20007" /> - + id="20008" /> - + - - + + id="30650" /> - + id="30880" /> - + id="30765" /> - + id="30001" /> - + id="30758" /> - + id="30027" /> - + id="30759" /> - + id="30010" /> - + id="30017" /> - + id="30018" /> - + id="30014" /> - + max1="1" max2="1" min2="1" /> - + max1="1" max2="1" min2="1" /> - + max1="1" max2="1" min2="1" /> - + @@ -13542,7 +13752,7 @@ render_pass="bump"> - + @@ -14232,7 +14442,7 @@ render_pass="bump"> max1="1" max2="1" min2="1" /> - + max1="1" max2="1" min2="1" /> - + @@ -14273,28 +14483,9 @@ render_pass="bump"> - + - - - - - - - - - - + id="30646" /> @@ -14322,7 +14513,7 @@ render_pass="bump"> - + @@ -15579,7 +15770,7 @@ render_pass="bump"> id="872" /> - + - + - + max1="1" max2="1" min2="1" /> - + - + @@ -63,11 +63,11 @@ + - @@ -220,7 +220,7 @@ - + From 4e3d76f52ebf099eb1201e6e1ae01cadc93acbbd Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Fri, 24 Jun 2016 09:46:34 -0400 Subject: [PATCH 03/16] SL-344 - additional slider updates, including scaling of mEye bones --- indra/newview/character/avatar_lad.xml | 381 ++++++++++++------------- 1 file changed, 181 insertions(+), 200 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 8b4d503eb1..77847c75e3 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -1489,32 +1489,32 @@ + offset="0.0045 0 0" /> + offset="0.0045 0 0" /> + offset="0.0045 0 0" /> + offset="0.018 0 0" /> + offset="0.018 0 0" /> + offset="0.018 0 0" /> + offset="0.015 0 0" /> + offset="0.015 0 0" /> + + - + + scale="0.25 0.25 0.25" + offset="-0.005 0 0" /> + scale="0.25 0.25 0.25" + offset="-0.005 0 0" /> + scale="0 0.3 0.7" + offset=" 0 0 0" /> + scale="0 0.3 0.7" + offset=" 0 0 0" /> + scale="0 0.3 0.7" + offset=" 0 0 0" /> + scale="0 0.3 0.7" + offset=" 0 0 0" /> + + - - - - - - - + scale="0 0.1 0.2" + offset=" 0 0 0" /> + + + + + + @@ -3488,159 +3498,124 @@ value_max="1" value_default="0"> - + + + - - - - - - - + name="mFaceForeheadCenter" + scale="0 0 0" + offset="0 0 -0.006" /> + - - + name="mFaceEyebrowOuterRight" + scale="0 0 0" + offset="0 -0.0053 -0.0047" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + name="mFaceEyebrowCenterRight" + scale="0 0 0" + offset="0 -0.0045 -0.0053" /> + name="mFaceEyebrowInnerRight" + scale="0 0 0" + offset="0 -0.00225 -0.0048" /> + + + name="mFaceEyebrowCenterLeft" + scale="0 0 0" + offset="0 0.0045 -0.0053" /> - + name="mFaceEyebrowInnerLeft" + scale="0 0 0" + offset="0 0.00225 -0.0048" /> + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -4291,12 +4266,22 @@ + offset="0 -0.0026 0.00245" /> + offset="0 -0.0026 0.00245" /> + + + + + offset="0 -0.0017 0.007" /> + offset="0 0.0 0.0055" /> - - - - + offset="0 0.0 0.0055" /> + offset="0 -0.001 0.007" /> + offset="0 0.001 0.007" /> + @@ -6523,7 +6502,7 @@ label_max="Anime Eyes" value_min="-2" value_max="2" - show_simple="true" + show_simple="true" value_default="0"> @@ -14798,6 +14777,7 @@ render_pass="bump"> camera_elevation=".1" camera_distance=".35"> + @@ -14815,6 +14795,7 @@ render_pass="bump"> + From 84bdf7f626e21260cabdba2dc108a4c35dfb1afe Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Sat, 25 Jun 2016 08:54:41 -0400 Subject: [PATCH 04/16] SL-344 - fixes for scaling of mEye and mAltEye bones --- indra/newview/character/avatar_lad.xml | 62 ++++++++++++++++---------- 1 file changed, 38 insertions(+), 24 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 77847c75e3..c6294f582f 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -2071,30 +2071,6 @@ value_max="1"> - - - - - - - - - + + + + + + + + + + + + + + + + + From 880fd82d0be58aa4cc5ea16518d15fed3178aa29 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Wed, 6 Jul 2016 20:06:50 -0400 Subject: [PATCH 05/16] SL-424 - more proposed skeleton/slider fixes --- indra/newview/character/avatar_lad.xml | 926 ++++++++------------ indra/newview/character/avatar_skeleton.xml | 81 +- 2 files changed, 430 insertions(+), 577 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index c6294f582f..ddf497f05b 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -1421,6 +1421,11 @@ value_min="-1" value_max="1"> + + - - + offset="0.005 0 0" /> + offset="0.005 0 0" /> - - - - - - + offset="0.005 0 0" /> + offset="0.005 0 0" /> + offset="0.005 0 0" /> + + + + + + + - - - - + offset="0.007 0 0" /> + + + + scale="0.3 0 0" + offset="0 0 0" /> + offset="0.004 0 0" /> - + + + + offset = "0.0 0.0 0.0" + scale = "0.50 0.3 0.1" /> + offset = "0 0 0" + scale = "0.0 0.3 0.0" /> + offset = "0 0 0" + scale = "0.0 0.3 0.0" /> + offset = "0.001 0.013 0"/> + offset = "-0.001 -0.013 0" /> @@ -2450,42 +2455,42 @@ + offset = "-0.008 0.00 0.0" /> + offset = "-0.009 0.00 0.0025" /> + offset = "-0.009 0.00 0.0025" /> + offset = "-0.009 0.00 0.0025" /> + offset = "-0.008 0.00 0.0" /> + offset = "-0.008 0.00 -0.0015" /> + offset = "-0.008 0.00 -0.0025" /> + offset = "-0.008 0.00 -0.0015" /> @@ -2510,17 +2515,17 @@ + scale = "0.2 0.00 0.4" + offset = "0.004 0.00 0.004" /> + scale = "0.2 0.00 0.4" + offset = "0.004 0.00 0.004" /> + scale = "0.2 0.00 0.4" + offset = "0.004 0.00 0.004" /> + offset = "-0.004 0.00 0.006" /> + offset = "-0.004 0.00 0.003" /> + offset = "-0.004 0.00 0.006" /> - - - - - - - - - - - - - - - - - - - - - - - + + + + name = "mFaceLipUpperLeft" + scale = "0 0 0.3" + offset = "0 0 0.003" /> + + - - - - + + + + - - - - - - + + + + + + + + + + - + - - - - - - - - - - - - - - - - + offset = "0.0 -0.006 0.0" /> + offset = "0.0 -0.006 0.0" /> @@ -3021,55 +2951,15 @@ scale = "0.0 0.00 0.0" offset = "0.0 0.003 0.0" /> - - - - - - - - - - - - - - - - + offset = "0.0 0.006 0.0" /> + offset = "0.0 0.006 0.0" /> @@ -3140,7 +3030,7 @@ @@ -3163,46 +3053,14 @@ id="30760" group="1" name="Jaw_Angle" - value_min="-2" + value_min="-1.2" value_max="2" - value_default="0"> + value_default="0"> - - - - - - - - - - - - - - @@ -3214,42 +3072,17 @@ value_min="-2" value_max="2"> - - - - - - - - - - @@ -3305,11 +3138,10 @@ value_min="-.5" value_max="1.5"> - - + @@ -3589,171 +3421,15 @@ name="mFaceCheekLowerLeft" scale="0 0 0" offset="0 0.003 0.0032" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + - - - - - - - - - - - - - - - - - - + offset="0 0 0.0016" /> @@ -3981,15 +3657,14 @@ value_max="3"> - - - + + @@ -4021,6 +3696,11 @@ + + + + + scale="0.0 -0.2 0.0" + offset="0.0 0 0.0" /> + scale="0.0 -0.2 0.0" + offset="0.0 0 0.0" /> + scale="0.0 -1.0 0.0" + offset="0.0 0.01 -0.01" /> + scale="0.0 -0.8 0.0" + offset="0.0 -0.01 -0.01" /> + + @@ -4236,28 +3926,18 @@ + offset="0 -0.0033 0.0025" /> - - - - + offset="0 -0.0033 0.002" /> - + + offset="0 0.0033 0.0025" /> - - - - + offset="0 0.0033 0.002" /> - + offset="0 0.00225 0.008" /> + - + offset="0 0 0" /> - - - + offset="0 0 0" /> + offset="0 0 0" /> + offset="0 0 0.0075" /> + + + offset="0 0 -0.00" /> + offset="0 0 0.0085" /> + offset="0 0 0.0085" /> - + + @@ -4436,6 +4102,179 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -15254,6 +15094,10 @@ render_pass="bump"> + + + @@ -15718,6 +15562,8 @@ render_pass="bump"> + @@ -15741,6 +15587,8 @@ render_pass="bump"> + @@ -15763,6 +15611,8 @@ render_pass="bump"> + diff --git a/indra/newview/character/avatar_skeleton.xml b/indra/newview/character/avatar_skeleton.xml index 025d12dd2e..2c63b8092d 100644 --- a/indra/newview/character/avatar_skeleton.xml +++ b/indra/newview/character/avatar_skeleton.xml @@ -1,4 +1,4 @@ - + @@ -20,9 +20,9 @@ - - - + + + @@ -48,27 +48,30 @@ - + - - - - - - - - + + + + + + + + + + - - - - - + - - + + + + + + + @@ -103,9 +106,9 @@ - - - + + + @@ -140,9 +143,9 @@ - - - + + + @@ -210,20 +213,20 @@ - - - - + + + + + - - - - - - + + + + + + - - + - + From 888ed6d620619d3ce6dddcc8e453c3f1e6713e99 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Fri, 8 Jul 2016 14:51:30 -0400 Subject: [PATCH 06/16] SL-242 - additional fixes for egghead slider --- indra/newview/character/avatar_lad.xml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index ddf497f05b..6aef67f1b7 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -3926,7 +3926,7 @@ + offset="0 0.00225 0.001" /> id="186" /> From 9d8986337aca6c7909a4c5ad836874d78b4625e5 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Fri, 8 Jul 2016 15:36:50 -0400 Subject: [PATCH 07/16] SL-242 - fix for slider param groups, added default args for skel_tool.py --- indra/newview/character/avatar_lad.xml | 10 +++++----- scripts/content_tools/skel_tool.py | 8 ++++---- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 6aef67f1b7..76a603db06 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -3897,7 +3897,7 @@ diff --git a/scripts/content_tools/skel_tool.py b/scripts/content_tools/skel_tool.py index f7301c55e1..7dabadb2b8 100644 --- a/scripts/content_tools/skel_tool.py +++ b/scripts/content_tools/skel_tool.py @@ -366,17 +366,17 @@ if __name__ == "__main__": parser = argparse.ArgumentParser(description="process SL avatar_skeleton/avatar_lad files") parser.add_argument("--verbose", action="store_true",help="verbose flag") - parser.add_argument("--ogfile", help="specify file containing base bones") + parser.add_argument("--ogfile", help="specify file containing base bones", default="avatar_skeleton_orig.xml") parser.add_argument("--ref_file", help="specify another file containing replacements for missing fields") - parser.add_argument("--lad_file", help="specify avatar_lad file to check") - parser.add_argument("--orig_lad_file", help="specify avatar_lad file to compare to") + parser.add_argument("--lad_file", help="specify avatar_lad file to check", default="avatar_lad.xml") + parser.add_argument("--orig_lad_file", help="specify avatar_lad file to compare to", default="avatar_lad_orig.xml") parser.add_argument("--aliases", help="specify file containing bone aliases") parser.add_argument("--validate", action="store_true", help="check specified input file for validity") parser.add_argument("--fix", action="store_true", help="try to correct errors") parser.add_argument("--remove", nargs="+", help="remove specified joints") parser.add_argument("--list", action="store_true", help="list joint names") parser.add_argument("--compare", help="alternate skeleton file to compare") - parser.add_argument("infilename", help="name of a skel .xml file to input") + parser.add_argument("infilename", help="name of a skel .xml file to input", default="avatar_skeleton.xml") parser.add_argument("outfilename", nargs="?", help="name of a skel .xml file to output") args = parser.parse_args() From 2929922ef2094dc0f2c2659de1d459b50aafe866 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Mon, 11 Jul 2016 18:00:59 -0400 Subject: [PATCH 08/16] SL-242 - more tweaks around alt eyes and wings. Alt eyes are now parented to face root, and alt eyes animate along with the original eyes inside the LLHeadRotMotion code. --- indra/llcharacter/llheadrotmotion.cpp | 205 +++++---- indra/llcharacter/llheadrotmotion.h | 4 + indra/newview/character/avatar_lad.xml | 452 +++++++++++++------- indra/newview/character/avatar_skeleton.xml | 10 +- 4 files changed, 432 insertions(+), 239 deletions(-) diff --git a/indra/llcharacter/llheadrotmotion.cpp b/indra/llcharacter/llheadrotmotion.cpp index 812c4201af..e91de7a11d 100644 --- a/indra/llcharacter/llheadrotmotion.cpp +++ b/indra/llcharacter/llheadrotmotion.cpp @@ -285,7 +285,10 @@ LLEyeMotion::LLEyeMotion(const LLUUID &id) : LLMotion(id) mName = "eye_rot"; mLeftEyeState = new LLJointState; + mAltLeftEyeState = new LLJointState; + mRightEyeState = new LLJointState; + mAltRightEyeState = new LLJointState; } @@ -318,18 +321,38 @@ LLMotion::LLMotionInitStatus LLEyeMotion::onInitialize(LLCharacter *character) return STATUS_FAILURE; } + mAltLeftEyeState->setJoint( character->getJoint("mFaceEyeAltLeft") ); + if ( ! mAltLeftEyeState->getJoint() ) + { + LL_INFOS() << getName() << ": Can't get alt left eyeball joint." << LL_ENDL; + return STATUS_FAILURE; + } + mRightEyeState->setJoint( character->getJoint("mEyeRight") ); if ( ! mRightEyeState->getJoint() ) { - LL_INFOS() << getName() << ": Can't get Right eyeball joint." << LL_ENDL; + LL_INFOS() << getName() << ": Can't get right eyeball joint." << LL_ENDL; + return STATUS_FAILURE; + } + + mAltRightEyeState->setJoint( character->getJoint("mFaceEyeAltRight") ); + if ( ! mAltRightEyeState->getJoint() ) + { + LL_INFOS() << getName() << ": Can't get alt right eyeball joint." << LL_ENDL; return STATUS_FAILURE; } mLeftEyeState->setUsage(LLJointState::ROT); + mAltLeftEyeState->setUsage(LLJointState::ROT); + mRightEyeState->setUsage(LLJointState::ROT); + mAltRightEyeState->setUsage(LLJointState::ROT); addJointState( mLeftEyeState ); + addJointState( mAltLeftEyeState ); + addJointState( mRightEyeState ); + addJointState( mAltRightEyeState ); return STATUS_SUCCESS; } @@ -343,17 +366,98 @@ BOOL LLEyeMotion::onActivate() return TRUE; } +//----------------------------------------------------------------------------- +// LLEyeMotion::adjustEyeTarget() +//----------------------------------------------------------------------------- +void LLEyeMotion::adjustEyeTarget(LLVector3* targetPos, LLJointState& left_eye_state, LLJointState& right_eye_state) +{ + // Compute eye rotation. + BOOL has_eye_target = FALSE; + LLQuaternion target_eye_rot; + LLVector3 eye_look_at; + F32 vergence; + + if (targetPos) + { + LLVector3 skyward(0.f, 0.f, 1.f); + LLVector3 left; + LLVector3 up; + + eye_look_at = *targetPos; + has_eye_target = TRUE; + F32 lookAtDistance = eye_look_at.normVec(); + + left.setVec(skyward % eye_look_at); + up.setVec(eye_look_at % left); + + target_eye_rot = LLQuaternion(eye_look_at, left, up); + // convert target rotation to head-local coordinates + target_eye_rot *= ~mHeadJoint->getWorldRotation(); + // eliminate any Euler roll - we're lucky that roll is applied last. + F32 roll, pitch, yaw; + target_eye_rot.getEulerAngles(&roll, &pitch, &yaw); + target_eye_rot.setQuat(0.0f, pitch, yaw); + // constrain target orientation to be in front of avatar's face + target_eye_rot.constrain(EYE_ROT_LIMIT_ANGLE); + + // calculate vergence + F32 interocular_dist = (left_eye_state.getJoint()->getWorldPosition() - right_eye_state.getJoint()->getWorldPosition()).magVec(); + vergence = -atan2((interocular_dist / 2.f), lookAtDistance); + llclamp(vergence, -F_PI_BY_TWO, 0.f); + } + else + { + target_eye_rot = LLQuaternion::DEFAULT; + vergence = 0.f; + } + + //RN: subtract 4 degrees to account for foveal angular offset relative to pupil + vergence += 4.f * DEG_TO_RAD; + + // calculate eye jitter + LLQuaternion eye_jitter_rot; + + // vergence not too high... + if (vergence > -0.05f) + { + //...go ahead and jitter + eye_jitter_rot.setQuat(0.f, mEyeJitterPitch + mEyeLookAwayPitch, mEyeJitterYaw + mEyeLookAwayYaw); + } + else + { + //...or don't + eye_jitter_rot.loadIdentity(); + } + + // calculate vergence of eyes as an object gets closer to the avatar's head + LLQuaternion vergence_quat; + + if (has_eye_target) + { + vergence_quat.setQuat(vergence, LLVector3(0.f, 0.f, 1.f)); + } + else + { + vergence_quat.loadIdentity(); + } + + // calculate eye rotations + LLQuaternion left_eye_rot = target_eye_rot; + left_eye_rot = vergence_quat * eye_jitter_rot * left_eye_rot; + + LLQuaternion right_eye_rot = target_eye_rot; + vergence_quat.transQuat(); + right_eye_rot = vergence_quat * eye_jitter_rot * right_eye_rot; + + left_eye_state.setRotation( left_eye_rot ); + right_eye_state.setRotation( right_eye_rot ); +} //----------------------------------------------------------------------------- // LLEyeMotion::onUpdate() //----------------------------------------------------------------------------- BOOL LLEyeMotion::onUpdate(F32 time, U8* joint_mask) { - // Compute eye rotation. - LLQuaternion target_eye_rot; - LLVector3 eye_look_at; - F32 vergence; - //calculate jitter if (mEyeJitterTimer.getElapsedTimeF32() > mEyeJitterTime) { @@ -426,83 +530,10 @@ BOOL LLEyeMotion::onUpdate(F32 time, U8* joint_mask) } } - BOOL has_eye_target = FALSE; LLVector3* targetPos = (LLVector3*)mCharacter->getAnimationData("LookAtPoint"); - if (targetPos) - { - LLVector3 skyward(0.f, 0.f, 1.f); - LLVector3 left; - LLVector3 up; - - eye_look_at = *targetPos; - has_eye_target = TRUE; - F32 lookAtDistance = eye_look_at.normVec(); - - left.setVec(skyward % eye_look_at); - up.setVec(eye_look_at % left); - - target_eye_rot = LLQuaternion(eye_look_at, left, up); - // convert target rotation to head-local coordinates - target_eye_rot *= ~mHeadJoint->getWorldRotation(); - // eliminate any Euler roll - we're lucky that roll is applied last. - F32 roll, pitch, yaw; - target_eye_rot.getEulerAngles(&roll, &pitch, &yaw); - target_eye_rot.setQuat(0.0f, pitch, yaw); - // constrain target orientation to be in front of avatar's face - target_eye_rot.constrain(EYE_ROT_LIMIT_ANGLE); - - // calculate vergence - F32 interocular_dist = (mLeftEyeState->getJoint()->getWorldPosition() - mRightEyeState->getJoint()->getWorldPosition()).magVec(); - vergence = -atan2((interocular_dist / 2.f), lookAtDistance); - llclamp(vergence, -F_PI_BY_TWO, 0.f); - } - else - { - target_eye_rot = LLQuaternion::DEFAULT; - vergence = 0.f; - } - - //RN: subtract 4 degrees to account for foveal angular offset relative to pupil - vergence += 4.f * DEG_TO_RAD; - - // calculate eye jitter - LLQuaternion eye_jitter_rot; - - // vergence not too high... - if (vergence > -0.05f) - { - //...go ahead and jitter - eye_jitter_rot.setQuat(0.f, mEyeJitterPitch + mEyeLookAwayPitch, mEyeJitterYaw + mEyeLookAwayYaw); - } - else - { - //...or don't - eye_jitter_rot.loadIdentity(); - } - - // calculate vergence of eyes as an object gets closer to the avatar's head - LLQuaternion vergence_quat; - - if (has_eye_target) - { - vergence_quat.setQuat(vergence, LLVector3(0.f, 0.f, 1.f)); - } - else - { - vergence_quat.loadIdentity(); - } - - // calculate eye rotations - LLQuaternion left_eye_rot = target_eye_rot; - left_eye_rot = vergence_quat * eye_jitter_rot * left_eye_rot; - - LLQuaternion right_eye_rot = target_eye_rot; - vergence_quat.transQuat(); - right_eye_rot = vergence_quat * eye_jitter_rot * right_eye_rot; - - mLeftEyeState->setRotation( left_eye_rot ); - mRightEyeState->setRotation( right_eye_rot ); + adjustEyeTarget(targetPos, *mLeftEyeState, *mRightEyeState); + adjustEyeTarget(targetPos, *mAltLeftEyeState, *mAltRightEyeState); return TRUE; } @@ -519,11 +550,23 @@ void LLEyeMotion::onDeactivate() joint->setRotation(LLQuaternion::DEFAULT); } + joint = mAltLeftEyeState->getJoint(); + if (joint) + { + joint->setRotation(LLQuaternion::DEFAULT); + } + joint = mRightEyeState->getJoint(); if (joint) { joint->setRotation(LLQuaternion::DEFAULT); } + + joint = mAltRightEyeState->getJoint(); + if (joint) + { + joint->setRotation(LLQuaternion::DEFAULT); + } } // End diff --git a/indra/llcharacter/llheadrotmotion.h b/indra/llcharacter/llheadrotmotion.h index 569dbef2dd..53ae1813bc 100644 --- a/indra/llcharacter/llheadrotmotion.h +++ b/indra/llcharacter/llheadrotmotion.h @@ -176,6 +176,8 @@ public: // it will be deactivated virtual BOOL onActivate(); + void adjustEyeTarget(LLVector3* targetPos, LLJointState& left_eye_state, LLJointState& right_eye_state); + // called per time step // must return TRUE while it is active, and // must return FALSE when the motion is completed. @@ -193,6 +195,8 @@ public: LLJoint *mHeadJoint; LLPointer mLeftEyeState; LLPointer mRightEyeState; + LLPointer mAltLeftEyeState; + LLPointer mAltRightEyeState; LLFrameTimer mEyeJitterTimer; F32 mEyeJitterTime; diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 76a603db06..e9ce4725e5 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -807,6 +807,39 @@ + + + + + + + + + + + + + @@ -1163,56 +1196,57 @@ name="mEyeRight" scale="0 0 0" offset="0 -.009 0" /> - - + offset="0 .0090 0" /> - + offset="0 -.0090 0" /> + + offset="0 .0090 0" /> + offset="0 -.0090 0" /> + + offset="0 .0090 0" /> + offset="0 -.0090 0" /> + offset="0 .0090 0" /> + offset="0 -.0090 0" /> + offset="0 .0090 0" /> + offset="0 -.0090 0" /> - - - + offset="0 0 -.004" /> - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - @@ -1584,6 +1488,7 @@ name="mEyeRight" scale="0 0 0" offset=".005 0 0" /> + - + - + + offset="0 0 -0.001" /> - + offset="0 0 -0.001" /> + + + + + @@ -3173,6 +3088,16 @@ name="mFaceEyeLidUpperLeft" scale="0 0.1 0.2" offset=" 0 0 0" /> + + + + @@ -3351,6 +3276,16 @@ name="mFaceEyebrowInnerLeft" scale="0 0 0" offset="0 0.00225 -0.0048" /> + + + + + + + + @@ -3929,6 +3874,16 @@ offset = "0.015 0.00 0.005" scale = "0.0 0.0 0.0" /> + + + + - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/indra/newview/character/avatar_skeleton.xml b/indra/newview/character/avatar_skeleton.xml index 2c63b8092d..2241a12545 100644 --- a/indra/newview/character/avatar_skeleton.xml +++ b/indra/newview/character/avatar_skeleton.xml @@ -21,11 +21,11 @@ - - - - - + + + + + From 75ff4382d985436197ead8b459bab80869b7f680 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Mon, 11 Jul 2016 18:19:37 -0400 Subject: [PATCH 09/16] SL-242 - avatar_lad.xml syntax fix, added missing scale params to some skeletal distortions. --- indra/newview/character/avatar_lad.xml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index e9ce4725e5..8e8cff59a5 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -810,34 +810,44 @@ From 6fb759b4b5bf12d78013bf7cc97ee79d728c2cd4 Mon Sep 17 00:00:00 2001 From: Oz Linden Date: Tue, 12 Jul 2016 07:56:11 -0400 Subject: [PATCH 10/16] update default LSL hints file to match the server version --- .../app_settings/keywords_lsl_default.xml | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/indra/newview/app_settings/keywords_lsl_default.xml b/indra/newview/app_settings/keywords_lsl_default.xml index bb23ec04dc..d641883d5a 100644 --- a/indra/newview/app_settings/keywords_lsl_default.xml +++ b/indra/newview/app_settings/keywords_lsl_default.xml @@ -1007,7 +1007,7 @@ type integer value - 0x800 + 0x800 tooltip @@ -1617,7 +1617,7 @@ type string value - 0x0A0x0A0x0A + \\n\\n\\n tooltip Indicates the last line of a notecard was read. @@ -5511,7 +5511,7 @@ type integer value - 0x40 + 0x40 tooltip Controls whether the object can be grabbed.\nA grab is the default action when in third person, and is available as the hand tool in build mode. This is useful for physical objects that you don't want other people to be able to trivially disturb. The default is FALSE @@ -5520,7 +5520,7 @@ type integer value - 0x400 + 0x400 tooltip Prevent click-and-drag movement on all prims in the object. @@ -9802,15 +9802,17 @@ return string arguments - - Error - + + + Error + type integer tooltip An Experience error code to translate. - - + + + tooltip Returns a string describing the error code passed or the string corresponding with XP_ERROR_UNKNOWN_ERROR if the value is not a valid Experience error code. @@ -10160,7 +10162,7 @@ Parameters type - integer + list tooltip A list of PRIM_* property constants to return values of. @@ -10251,7 +10253,7 @@ Parameters type - integer + list tooltip PRIM_* flags. @@ -12172,7 +12174,7 @@ First type - string + integer tooltip Index of the first key to return. @@ -12181,7 +12183,7 @@ Count type - string + integer tooltip The number of keys to return. @@ -14797,7 +14799,7 @@ arguments - AvatarID + AgentID type key From b73137ca17f4ecf58ac6c695da5733fcb6b9edf2 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Tue, 12 Jul 2016 08:42:10 -0400 Subject: [PATCH 11/16] SL-242 - eyelid slider fix --- indra/newview/character/avatar_lad.xml | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 8e8cff59a5..5ce08fc732 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -3699,16 +3699,6 @@ - - - - From a1655f032dc68b246ac7e847e408c15a29df7ece Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Tue, 12 Jul 2016 15:06:48 -0400 Subject: [PATCH 12/16] SL-424 - slider eye fixes, tail scaling with height --- indra/newview/character/avatar_lad.xml | 70 ++++++++++++++++++++------ 1 file changed, 56 insertions(+), 14 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 5ce08fc732..9c7e50e8bb 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -850,6 +850,37 @@ scale="0 0 0" offset="-0.03 -0.03 0" /> + + + + + + + + + + + + + @@ -1991,6 +2022,27 @@ value_max="1"> + + + + + + + + + - - - - + offset="0 0 0" /> + offset="0 0 0" /> + offset="0 0 0" /> + offset="0 0 0" /> From e0c2a4ac336c7ecbfe4215a02a201d685e6d14fd Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Fri, 15 Jul 2016 10:52:29 -0400 Subject: [PATCH 13/16] SL-126 - getting performance analysis into a non-crashing state --- indra/newview/llfasttimerview.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/indra/newview/llfasttimerview.cpp b/indra/newview/llfasttimerview.cpp index 4a059fdc67..e9b5403dea 100644 --- a/indra/newview/llfasttimerview.cpp +++ b/indra/newview/llfasttimerview.cpp @@ -904,7 +904,8 @@ void LLFastTimerView::doAnalysisDefault(std::string baseline, std::string target base[label]["Samples"].asInteger()); } - exportCharts(baseline, target); + // BENTO - this currently crashes + // exportCharts(baseline, target); os.flush(); os.close(); From ba90b2d3c738378d0d8300ff0a449beb680e7914 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Mon, 8 Aug 2016 15:18:12 -0400 Subject: [PATCH 14/16] SL-433 - fix for mesh eye scaling with eye size slider. Previous values were based on incorrectly sized reference eyes. --- indra/newview/character/avatar_lad.xml | 58 +++++++++++++------------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 9c7e50e8bb..533ef95d3e 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -4065,38 +4065,38 @@ - - - - + + + + + + + + - + - - - - - + Date: Tue, 9 Aug 2016 09:17:37 -0400 Subject: [PATCH 15/16] SL-126 - attachment logging under avatar at DEBUG level. Also fixed a typo in avatar_lad.xml --- indra/newview/character/avatar_lad.xml | 2 +- indra/newview/llvoavatar.cpp | 4 ++-- indra/newview/llvovolume.cpp | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/indra/newview/character/avatar_lad.xml b/indra/newview/character/avatar_lad.xml index 533ef95d3e..a9f506d80b 100644 --- a/indra/newview/character/avatar_lad.xml +++ b/indra/newview/character/avatar_lad.xml @@ -871,7 +871,7 @@ offset="-0.02 0 0" /> diff --git a/indra/newview/llvoavatar.cpp b/indra/newview/llvoavatar.cpp index d3cd85e9f4..b1282fb4de 100644 --- a/indra/newview/llvoavatar.cpp +++ b/indra/newview/llvoavatar.cpp @@ -5606,11 +5606,11 @@ void LLVOAvatar::showAttachmentPosOverrides(bool verbose) const { std::stringstream ss; std::copy(joint_names.begin(), joint_names.end(), std::ostream_iterator(ss, ",")); - LL_INFOS() << getFullname() << " attachment positions defined for joints: " << ss.str() << "\n" << LL_ENDL; + LL_DEBUGS("Avatar") << getFullname() << " attachment positions defined for joints: " << ss.str() << "\n" << LL_ENDL; } else { - LL_INFOS() << getFullname() << " no attachment positions defined for any joints" << "\n" << LL_ENDL; + LL_DEBUGS("Avatar") << getFullname() << " no attachment positions defined for any joints" << "\n" << LL_ENDL; } if (!verbose) diff --git a/indra/newview/llvovolume.cpp b/indra/newview/llvovolume.cpp index 465f8fe0d6..c8e98683aa 100644 --- a/indra/newview/llvovolume.cpp +++ b/indra/newview/llvovolume.cpp @@ -4783,7 +4783,8 @@ void LLVolumeGeometryManager::rebuildGeom(LLSpatialGroup* group) pAvatarVO->addAttachmentPosOverridesForObject(vobj); if (pAvatarVO->isSelf()) { - //pAvatarVO->showAttachmentPosOverrides(); + bool verbose = true; + pAvatarVO->showAttachmentPosOverrides(verbose); } } From 95d9e85f9539c449f37c438b90a90e6ac73d3b87 Mon Sep 17 00:00:00 2001 From: "Brad Payne (Vir Linden)" Date: Tue, 9 Aug 2016 15:24:09 -0400 Subject: [PATCH 16/16] SL-109 - made viewer much less tolerant of bad data in avatar_skeleton.xml or avatar_lad.xml. If either of these is broken, there's no point trying to continue, more informative to just error out with an appropriate message. --- indra/llappearance/llavatarappearance.cpp | 41 ++++++++++--------- .../llappearance/llpolyskeletaldistortion.cpp | 4 +- 2 files changed, 24 insertions(+), 21 deletions(-) diff --git a/indra/llappearance/llavatarappearance.cpp b/indra/llappearance/llavatarappearance.cpp index 2ce43436db..acb43d23a1 100644 --- a/indra/llappearance/llavatarappearance.cpp +++ b/indra/llappearance/llavatarappearance.cpp @@ -593,7 +593,7 @@ BOOL LLAvatarAppearance::setupBone(const LLAvatarBoneInfo* info, LLJoint* parent { if (volume_num >= (S32)mNumCollisionVolumes) { - LL_WARNS() << "Too many bones" << LL_ENDL; + LL_WARNS() << "Too many collision volumes" << LL_ENDL; return FALSE; } joint = (&mCollisionVolumes[volume_num]); @@ -866,21 +866,21 @@ BOOL LLAvatarAppearance::loadAvatar() // avatar_skeleton.xml if( !buildSkeleton(sAvatarSkeletonInfo) ) { - LL_WARNS() << "avatar file: buildSkeleton() failed" << LL_ENDL; + LL_ERRS() << "avatar file: buildSkeleton() failed" << LL_ENDL; return FALSE; } // avatar_lad.xml : if( !loadSkeletonNode() ) { - LL_WARNS() << "avatar file: loadNodeSkeleton() failed" << LL_ENDL; + LL_ERRS() << "avatar file: loadNodeSkeleton() failed" << LL_ENDL; return FALSE; } // avatar_lad.xml : if( !loadMeshNodes() ) { - LL_WARNS() << "avatar file: loadNodeMesh() failed" << LL_ENDL; + LL_ERRS() << "avatar file: loadNodeMesh() failed" << LL_ENDL; return FALSE; } @@ -890,13 +890,13 @@ BOOL LLAvatarAppearance::loadAvatar() mTexSkinColor = new LLTexGlobalColor( this ); if( !mTexSkinColor->setInfo( sAvatarXmlInfo->mTexSkinColorInfo ) ) { - LL_WARNS() << "avatar file: mTexSkinColor->setInfo() failed" << LL_ENDL; + LL_ERRS() << "avatar file: mTexSkinColor->setInfo() failed" << LL_ENDL; return FALSE; } } else { - LL_WARNS() << " name=\"skin_color\" not found" << LL_ENDL; + LL_ERRS() << " name=\"skin_color\" not found" << LL_ENDL; return FALSE; } if( sAvatarXmlInfo->mTexHairColorInfo ) @@ -904,13 +904,13 @@ BOOL LLAvatarAppearance::loadAvatar() mTexHairColor = new LLTexGlobalColor( this ); if( !mTexHairColor->setInfo( sAvatarXmlInfo->mTexHairColorInfo ) ) { - LL_WARNS() << "avatar file: mTexHairColor->setInfo() failed" << LL_ENDL; + LL_ERRS() << "avatar file: mTexHairColor->setInfo() failed" << LL_ENDL; return FALSE; } } else { - LL_WARNS() << " name=\"hair_color\" not found" << LL_ENDL; + LL_ERRS() << " name=\"hair_color\" not found" << LL_ENDL; return FALSE; } if( sAvatarXmlInfo->mTexEyeColorInfo ) @@ -918,26 +918,26 @@ BOOL LLAvatarAppearance::loadAvatar() mTexEyeColor = new LLTexGlobalColor( this ); if( !mTexEyeColor->setInfo( sAvatarXmlInfo->mTexEyeColorInfo ) ) { - LL_WARNS() << "avatar file: mTexEyeColor->setInfo() failed" << LL_ENDL; + LL_ERRS() << "avatar file: mTexEyeColor->setInfo() failed" << LL_ENDL; return FALSE; } } else { - LL_WARNS() << " name=\"eye_color\" not found" << LL_ENDL; + LL_ERRS() << " name=\"eye_color\" not found" << LL_ENDL; return FALSE; } // avatar_lad.xml : if (sAvatarXmlInfo->mLayerInfoList.empty()) { - LL_WARNS() << "avatar file: missing node" << LL_ENDL; + LL_ERRS() << "avatar file: missing node" << LL_ENDL; return FALSE; } if (sAvatarXmlInfo->mMorphMaskInfoList.empty()) { - LL_WARNS() << "avatar file: missing node" << LL_ENDL; + LL_ERRS() << "avatar file: missing node" << LL_ENDL; return FALSE; } @@ -1136,6 +1136,7 @@ BOOL LLAvatarAppearance::loadMeshNodes() { // This should never happen LL_WARNS("Avatar") << "Could not find avatar mesh: " << info->mReferenceMeshName << LL_ENDL; + return FALSE; } } else @@ -1730,7 +1731,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlSkeletonNode(LLXmlTreeNode* ro { LL_WARNS() << "Unknown param type." << LL_ENDL; } - continue; + return FALSE; } LLPolySkeletalDistortionInfo *info = new LLPolySkeletalDistortionInfo; @@ -1755,7 +1756,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlSkeletonNode(LLXmlTreeNode* ro { LL_WARNS() << "No name supplied for attachment point." << LL_ENDL; delete info; - continue; + return FALSE; } static LLStdStringHandle joint_string = LLXmlTree::addAttributeString("joint"); @@ -1763,7 +1764,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlSkeletonNode(LLXmlTreeNode* ro { LL_WARNS() << "No bone declared in attachment point " << info->mName << LL_ENDL; delete info; - continue; + return FALSE; } static LLStdStringHandle position_string = LLXmlTree::addAttributeString("position"); @@ -1789,7 +1790,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlSkeletonNode(LLXmlTreeNode* ro { LL_WARNS() << "No id supplied for attachment point " << info->mName << LL_ENDL; delete info; - continue; + return FALSE; } static LLStdStringHandle slot_string = LLXmlTree::addAttributeString("pie_slice"); @@ -1875,7 +1876,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlMeshNodes(LLXmlTreeNode* root) { LL_WARNS() << "Unknown param type." << LL_ENDL; } - continue; + return FALSE; } LLPolyMorphTargetInfo *morphinfo = new LLPolyMorphTargetInfo(); @@ -2036,7 +2037,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlMorphNodes(LLXmlTreeNode* root { LL_WARNS() << "No name supplied for morph mask." << LL_ENDL; delete info; - continue; + return FALSE; } static LLStdStringHandle region_string = LLXmlTree::addAttributeString("body_region"); @@ -2044,7 +2045,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlMorphNodes(LLXmlTreeNode* root { LL_WARNS() << "No region supplied for morph mask." << LL_ENDL; delete info; - continue; + return FALSE; } static LLStdStringHandle layer_string = LLXmlTree::addAttributeString("layer"); @@ -2052,7 +2053,7 @@ BOOL LLAvatarAppearance::LLAvatarXmlInfo::parseXmlMorphNodes(LLXmlTreeNode* root { LL_WARNS() << "No layer supplied for morph mask." << LL_ENDL; delete info; - continue; + return FALSE; } // optional parameter. don't throw a warning if not present. diff --git a/indra/llappearance/llpolyskeletaldistortion.cpp b/indra/llappearance/llpolyskeletaldistortion.cpp index e9750ae6f5..8d71335175 100644 --- a/indra/llappearance/llpolyskeletaldistortion.cpp +++ b/indra/llappearance/llpolyskeletaldistortion.cpp @@ -150,8 +150,10 @@ BOOL LLPolySkeletalDistortion::setInfo(LLPolySkeletalDistortionInfo *info) LLJoint* joint = mAvatar->getJoint(bone_info->mBoneName); if (!joint) { + // There's no point continuing after this error - means + // that either the skeleton or lad file is broken. LL_WARNS() << "Joint " << bone_info->mBoneName << " not found." << LL_ENDL; - continue; + return FALSE; } // store it