Exemple #1
0
def slerp(a, b, t):
	raise NotImplementedError

	cos_omega = vec4.dot(a, b)
	
	if (cos_omega < 0.0):
		cos_omega = -cos_omega
		b = vec4.neg(b)

	imega = math.acos(cos_omega)
	t = sin(t * omega) / sin(omega)

	return vec4.lerp(a, b, t)
Exemple #2
0
def slerp(a, b, t):
	raise NotImplementedError

	cos_omega= vec4.dot(a, b)
	
	if (cos_omega<0.0):
		cos_omega= -cos_omega
		b= vec4.neg(b)

	imega= math.acos(cos_omega)
	t= sin(t*omega)/sin(omega)

	return vec4.lerp(a, b, t)
Exemple #3
0
def transmulvec4(m_trans,v):
	return tuple([vec4.dot(v, m_c) for m_c in m_trans])