假设我有2个3D矢量
Vec3 v1, v2;
v1.x = 203;
v1.y = 355;
v1.z = 922;
v2.x = 6;
v2.y = 13;
v2.z = 198;
我如何计算v1
&之间的角度? v2
?即最终答案将在0
到360
我试过
Vec3 angle = v1 - v2;
还有一些其他的东西,但我似乎无法让它正常工作。
答案 0 :(得分:1)
您需要使用dot product来实现此目标,一旦完成,您就可以关注standard method。 例如:
if (This an intentional behavior of the variadic syntax) {
Can someone reference some documentation so that I can learn more?
} else if (This a known clang decision or problem) {
Can someone reference some discussion?
} else {
Can someone please name the issue / mistake?
}