问题描述
这里是 Android 新手.
New to Android here.
SDK 中是否有 Android 2.2 3D 数学库?我找不到一个,我希望会有一个.由于某种原因,我无法在 Eclipse 中使用 javax.* 包.
Is there an Android 2.2 3D math library in the SDK? I couldn't find one and I was hoping there would be one. I am not able to use javax.* packages for some reason in Eclipse.
我真正需要的是围绕任意角度的任意轴旋转.
The thing I really need is rotation about an arbitrary axis of an arbitrary angle.
除非迫不得已,否则我真的不想使用 NDK.如果有免费的 Java 3d 数学库,我很想知道.它应该适用于Android.
I don't really want to use the NDK unless I am forced to. If there is a freely available Java 3d math library, I would love to know. It should work with Android.
理想情况下,它应该具有基本的 3d 数学,如 cross()、dot() 等,以及任意旋转和缩放.
It should ideally have basic 3d math like cross(), dot(), etc. along with arbitrary rotation and scaling.
谢谢,
推荐答案
我刚刚将 vecmath 源代码放入我的项目中,除了 Color* 类之外,它似乎可以正常编译和工作(这不是什么大损失).
I just dropped the vecmath source in to my project and it seems to compile and work fine apart from Color* classes (which is no great loss).
这篇关于Android 3d 数学库(向量、矩阵等)类似于 javax.vecmath.Matrix4f.rotate()的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!