mirror of
https://github.com/ApfelTeeSaft/vb01.git
synced 2026-08-26 19:33:45 +00:00
improved bone test
remade IK chain bone orientation method
This commit is contained in:
+2
-1
@@ -7,7 +7,8 @@ namespace vb01{
|
||||
for(int i = 0; i < chainLength; i++)
|
||||
sumLengths += boneChain[i]->getLength();
|
||||
|
||||
Vector3 startPos = boneChain[chainLength - 1]->getModelSpacePos();
|
||||
Bone *subBase = (Bone*)boneChain[0]->getIkTarget()->getParent();
|
||||
Vector3 startPos = boneChain[chainLength - 1]->getBoneSpaceRestPos(subBase);
|
||||
if(startPos.getDistanceFrom(targetPos) < sumLengths){
|
||||
int numIterations = 500;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user