diff options
author | diva | 2009-03-27 20:18:55 +0000 |
---|---|---|
committer | diva | 2009-03-27 20:18:55 +0000 |
commit | bce5ed5812cc4385852a324da8a478086a7a0d37 (patch) | |
tree | 4f7d83e404137e236bd61b021f392eeb34632f3b /OpenSim/Framework | |
parent | * minor: remove one mono compiler warning (diff) | |
download | opensim-SC-bce5ed5812cc4385852a324da8a478086a7a0d37.zip opensim-SC-bce5ed5812cc4385852a324da8a478086a7a0d37.tar.gz opensim-SC-bce5ed5812cc4385852a324da8a478086a7a0d37.tar.bz2 opensim-SC-bce5ed5812cc4385852a324da8a478086a7a0d37.tar.xz |
Moved a method GetDefaultVisualParameters from Scene to AvatarAppearance, where it belongs. Better error handling in ScenePresence.CopyFrom.
Diffstat (limited to 'OpenSim/Framework')
-rw-r--r-- | OpenSim/Framework/AvatarAppearance.cs | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/OpenSim/Framework/AvatarAppearance.cs b/OpenSim/Framework/AvatarAppearance.cs index 9544d5a..8d0d699 100644 --- a/OpenSim/Framework/AvatarAppearance.cs +++ b/OpenSim/Framework/AvatarAppearance.cs | |||
@@ -321,12 +321,12 @@ namespace OpenSim.Framework | |||
321 | + 0.08f * (float)m_visualparams[77] / 255.0f // Shoe heel height | 321 | + 0.08f * (float)m_visualparams[77] / 255.0f // Shoe heel height |
322 | + 0.07f * (float)m_visualparams[78] / 255.0f // Shoe platform height | 322 | + 0.07f * (float)m_visualparams[78] / 255.0f // Shoe platform height |
323 | + 0.076f * (float)m_visualparams[148] / 255.0f; // Neck length | 323 | + 0.076f * (float)m_visualparams[148] / 255.0f; // Neck length |
324 | m_hipOffset = (0.615385f // Half of avatar | 324 | m_hipOffset = (0.615385f // Half of avatar |
325 | + 0.08f * (float)m_visualparams[77] / 255.0f // Shoe heel height | 325 | + 0.08f * (float)m_visualparams[77] / 255.0f // Shoe heel height |
326 | + 0.07f * (float)m_visualparams[78] / 255.0f // Shoe platform height | 326 | + 0.07f * (float)m_visualparams[78] / 255.0f // Shoe platform height |
327 | + 0.3836f * (float)m_visualparams[125] / 255.0f // Leg length | 327 | + 0.3836f * (float)m_visualparams[125] / 255.0f // Leg length |
328 | - m_avatarHeight / 2) * 0.3f - 0.04f; | 328 | - m_avatarHeight / 2) * 0.3f - 0.04f; |
329 | //m_log.Debug(">>>>>>> [APPEARANCE]: Height {0} Hip offset {1}", m_avatarHeight, m_hipOffset); | 329 | //System.Console.WriteLine(">>>>>>> [APPEARANCE]: Height {0} Hip offset {1}" + m_avatarHeight + " " + m_hipOffset); |
330 | //m_log.Debug("------------- Set Appearance Texture ---------------"); | 330 | //m_log.Debug("------------- Set Appearance Texture ---------------"); |
331 | //Primitive.TextureEntryFace[] faces = Texture.FaceTextures; | 331 | //Primitive.TextureEntryFace[] faces = Texture.FaceTextures; |
332 | //foreach (Primitive.TextureEntryFace face in faces) | 332 | //foreach (Primitive.TextureEntryFace face in faces) |
@@ -358,6 +358,17 @@ namespace OpenSim.Framework | |||
358 | return textu; | 358 | return textu; |
359 | } | 359 | } |
360 | 360 | ||
361 | public static byte[] GetDefaultVisualParams() | ||
362 | { | ||
363 | byte[] visualParams; | ||
364 | visualParams = new byte[VISUALPARAM_COUNT]; | ||
365 | for (int i = 0; i < VISUALPARAM_COUNT; i++) | ||
366 | { | ||
367 | visualParams[i] = 100; | ||
368 | } | ||
369 | return visualParams; | ||
370 | } | ||
371 | |||
361 | public override String ToString() | 372 | public override String ToString() |
362 | { | 373 | { |
363 | String s = "[Wearables] =>"; | 374 | String s = "[Wearables] =>"; |