SA.FullBodyIK.ComputeCosTheta C# (CSharp) Method

ComputeCosTheta() public static method

public static ComputeCosTheta ( float lenASq, float lenBSq, float lenCSq, float lenB, float lenC ) : float
lenASq float
lenBSq float
lenCSq float
lenB float
lenC float
return float
		public static float ComputeCosTheta(
			float lenASq,
			float lenBSq,
			float lenCSq,
			float lenB,
			float lenC )
		{
			float bc2 = lenB * lenC * 2.0f;
			if( bc2 > IKEpsilon ) {
				return (lenBSq + lenCSq - lenASq) / bc2;
			}

			return 1.0f;
		}

Same methods

FullBodyIK::ComputeCosTheta ( FastLength lenA, FastLength lenB, FastLength lenC ) : float
FullBodyIK