Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-07-29 21:49:14 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-07-29 21:49:14 +0400
commitf608b3c44402ef5c58217481d93e7fa83c9cd7cf (patch)
treecc8211154eb5a3cf9e1d89484cbe48facd51b90e /source/blender/ikplugin/intern/itasc_plugin.cpp
parentc41e1e434ab9defa35178ad8886d81b60d889e9a (diff)
code cleanup:
- building without python works again - rename maxi/mini to i_max/i_min (so thay are available for function names) - some minor edits to IK stretch setting (no functional changes).
Diffstat (limited to 'source/blender/ikplugin/intern/itasc_plugin.cpp')
-rw-r--r--source/blender/ikplugin/intern/itasc_plugin.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/ikplugin/intern/itasc_plugin.cpp b/source/blender/ikplugin/intern/itasc_plugin.cpp
index 1154605c673..516a4c7fdda 100644
--- a/source/blender/ikplugin/intern/itasc_plugin.cpp
+++ b/source/blender/ikplugin/intern/itasc_plugin.cpp
@@ -1254,8 +1254,9 @@ static IK_Scene *convert_tree(Scene *blscene, Object *ob, bPoseChannel *pchan)
joint = bone->name;
joint += ":TY";
ret = arm->addSegment(joint, parent, KDL::Joint::TransY, rot[ikchan->ndof - 1]);
- float ikstretch = pchan->ikstretch * pchan->ikstretch;
- weight[1] = (1.0 - minf(1.0 - ikstretch, 0.99));
+ const float ikstretch = pchan->ikstretch * pchan->ikstretch;
+ /* why invert twice here? */
+ weight[1] = (1.0 - minf(1.0 - ikstretch, 1.0f - IK_STRETCH_STIFF_EPS));
weights.push_back(weight[1]);
}
if (!ret)