在 J2ME M3G 中查找对象
我使用 Blender 创建 m3g 文件,然后将它们加载到 java 程序中。
在 World
中查找对象(Mesh
)的最佳方法是什么? (我应该如何“构建”一个世界?)
我应该为每个对象创建单独的类,然后将它们添加到一个 World
对象中,还是应该为 Blender 中的对象分配 ID 并在程序中找到它们通过 ID?
或者将每个对象导出到单独的 M3G 文件?
(或者其他方式?)
I'm using Blender to create m3g files and then I load them in a java program.
Which is the best way to find an object (a Mesh
) in the World
? (How should I "build" a world?)
Should I create separate classes for every object and then add them to one World
object or should I assign IDs to the objects in Blender and find them in the program by ID?
Or export every object to a separate M3G file?
(Or some other way?)
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Q1.如果您知道
网格
的ID (MESH_ID
),那么:Q2。加载基本的
World
:然后使用 API 创建更多对象并将其添加到世界中 API 文档对此进行了深入介绍:
第 3 季度。在 Blender 中分配它们,然后使用
find
方法获取您需要的Object3D
的确切实例。Q4。如果您计划重用网格(针对不同的应用程序),请将它们组织到单独的文件中,在应用程序初始化期间单独加载它们,然后将它们插入到世界中。
Q1. If you know the ID of the
Mesh
(MESH_ID
), then:Q2. Load a basic
World
:Then use the API to create and add more objects into the world The API documentation covers this in depth:
Q3. Assign them in Blender, then use the
find
method to get the exact instance ofObject3D
you need.Q4. If you plan on reusing meshes (for different applications), organize them into separate files, load them separately during initialization of an application, and then insert them into the world.