如何检索每个轴上的3D旋转角度?

dim*_*mio 5 .net c# wpf rotation

我有一个Model3DGroup,它使用应用于对象的Transform属性的AxisAngleRotation3D围绕x,y,z轴中的任何一个旋转.

问题是我无法控制网格上应用的各种旋转.我需要在每个渲染循环的每个x,y,z轴上显示网格的角度.

我怎样才能做到这一点?我尝试在对象上检索AxisAngleRotation3D对象,但它只给出了上次应用的旋转.哪个不对.

例如,如果应用了Axis的旋转:Vector3D(1,1,0)角度:45

绕Z轴的实际旋转不是0.如何获得每个轴上的实际角度?

And*_*eas 2

 double rotationX = Vector3D.AngleBetween(new Vector3D(1, 0, 0), yourMatrix3D.Transform(new Vector3D(1, 0, 0)));
 double rotationY = Vector3D.AngleBetween(new Vector3D(0, 1, 0), yourMatrix3D.Transform(new Vector3D(0, 1, 0)));
 double rotationZ = Vector3D.AngleBetween(new Vector3D(0, 0, 1), yourMatrix3D.Transform(new Vector3D(0, 0, 1)));
Run Code Online (Sandbox Code Playgroud)