简体   繁体   English

是否可以将iPhone的.obj文件从Lightwave 3D转换为.h文件,以用于OpenGL ES?

[英]Is there a way to convert a .obj file from Lightwave 3D to .h file for OpenGL ES in iPhone?

I am looking for a way to convert a .obj file of Lightwave 3D to a .h file for iPhone. 我正在寻找一种将Lightwave 3D的.obj文件转换为iPhone的.h文件的方法。 I looked around and has seen several scripts that can generate .h files for you, but all of them cannot understand Lightwave 3D .obj format. 我环顾四周,看到了几个可以为您生成.h文件的脚本,但是它们全部都无法理解Lightwave 3D .obj格式。 If anyone appears to know some sort of methods that can translate lightwave 3d .obj files to .h file, please share. 如果有人似乎知道某种可以将lightwave 3d .obj文件转换为.h文件的方法,请分享。

Or better, if anyone appears to know some other ways to make .h files, please advice. 或者更好的是,如果有人似乎知道制作.h文件的其他方法,请提出建议。 Thank you. 谢谢。

也许将.obj文件转换为Blender文件,然后从中导出头文件

Jeff Lamarche also has a number of posts on conversion of Blender files to .h files under the OpenGL ES tag at his blog. Jeff Lamarche在他的博客上还发表了许多有关将Blender文件转换为OpenGL ES标签下的.h文件的文章。 He's posted a Python script that was iteratively improved by the community (notably Scott Lyons and Dennis Ippel). 他发布了一个Python脚本 ,该脚本已被社区(尤其是Scott Lyons和Dennis Ippel)进行了迭代改进。

I'm not aware of a script that does the export straight from Lightwave, so it currently looks like you'll have to go through Blender first... 我不知道直接从Lightwave导出的脚本,因此目前看来您必须先通过Blender。

Simon Maurice's OpenGL ES series has a 3 part article ( I , II & III ) on leveraging Blender's python interface to bring models into OpenGL ES iPhone applications. 西蒙·莫里斯(Simon Maurice)的OpenGL ES系列文章分为三部分( 第一第二第三部分 ),内容涉及如何利用Blender的python接口将模型引入OpenGL ES iPhone应用程序。 It includes a step-by-step guide and sample projects. 它包括分步指南和示例项目。

并非完全符合您的要求,但是我编写了逐步指南 ,介绍如何通过COLLADA将LightWave模型引入OpenGL ES。

www.cheetah3d.com上的Cheetah 3d是仅Mac的3d建模工具,可将obj导出为.h

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM