建议的文件格式和图形库导入3D模型转换成OpenGL / C ++项目?文件格式、转换成、图形、模型

2023-09-07 22:20:56 作者:欲罢不能 °

如果你想:

模型在3D编辑器中的对象,例如,搅拌机,玛雅等 模型导出到一个数据/文件格式 导入模型到使用OpenGL和C / C的项目++

然后:

您会推荐出口到,即简约,便携性和兼容性方面(即普通/流行)什么文件格式? 在什么图形库,你会推荐使用的模型导入到你的OpenGL C / C ++项目(即preferably开源的)? 此外,是否有数据/文件格式也捕获动画,即一个动画模型格式,以使得动画可以参照在3D编辑并以某种方式内的code调用(例如无障碍帧中动画序列或与之相关的随时间变化的一些其他的范例,保存/载入详情)?

一般来说,我在寻找简单的优先级,即帮助上手结合我的背景,在艺术和计算机科学。我是一名计算机科学专业的麻省大学,而在同一时间,有点伪双主修艺术通过在夏季/冬季会因此考虑在平面设计选修我的大学,以及课程在波士顿艺术学院换句话说,我不是一个完整的新手,但在同一时间,我真的不希望出现这种情况是如此超负荷疯狂高级的配置使得它太难上手了基本的示范项目的选择;即作为第一步,以了解如何弥合这两个世界之间的差距,例如:创建程序设有3D字符,用户可以与之交互

Generally speaking, I'm seeking simplicity as the priority, i.e. help to get started with combining my backgrounds in both art and computer science. I am a computer science major at UMass while at the same time, sort of a "pseudo" double-major in art by taking electives in graphic design at my university as well as classes at the Art Institute of Boston during summer/winter sessions So, in other words, I am not a complete newbie, but at the same time I don't really want options that are so overloaded with crazy advanced configurations making it too difficult to get started with a basic demonstration project; i.e. as a first step to understanding how to bridge the gap between these two worlds, e.g. creating a program featuring a 3D character that the user can interact with.

推荐答案

COLLADA (我说的是一个啊结尾),和 Assimp (PLE作为)。

所以,为什么COLLADA?简单:

And so, why COLLADA? Simple:

COLLADA,由Khronos发(索尼专)的开放标准。一个开放的标准格式的美妙之处在于它的,那么,一个标准!你可以放心,一个符合标准的产品的任何输出也将被其他符合标准的产品的正确读取。尽管悲哀地说,一些3D建模产品是不是特别的措施,符合标准的COLLADA。但是还是放心:搅拌机,玛雅,3ds Max和所有其他大牌在3D建模先后为格式的良好支持 COLLADA使用XML。这使得它更简单的你,如果你计划创建自己的读者或作家。 其他: COLLADA是,我认为,这是不依赖于特定公司的唯一格式。这对我们来说是一个非常好的事情,你知道的。 其他2:据了解,COLLADA是缓慢进行解析。确实如此。不过想起来:所有其他非二进制格式(比如FBX)也有同样的问题。为了你的需求,COLLADA应该足够了。 其他3: COLLADA支持动画 COLLADA is an open standard made by Khronos (Sony specifically). The beauty of an open standard format is that it's, well, a standard! You can be assured that any output of a standard-conformant product would also read correctly by another standard-conformant product. Sad to say though, some 3d modelling products aren't that particular in their measures for standards conformance for COLLADA. But still be rest assured: Blender, Maya, 3ds Max and all the other big names in 3d modelling has good support for the format. COLLADA uses XML. This makes it much more simpler for you if your planning to create your own reader or writer. ADDITIONAL: COLLADA is, I think, the only format that is not tied to a specific company. This is a very good thing for us, you know. ADDITIONAL 2: It is known that COLLADA is slow to be parsed. That's true. But think of it: all other non-binary formats (like fbx) have also the same issues. For your needs, COLLADA should suffice. ADDITIONAL 3: COLLADA supports animations!

有关进口商库,我强烈建议Assimp。为什么呢?

For the importer library, I highly recommend Assimp. Why?

Assimp有任何流行的格式,你可以想像的支持。它有一个统一的接口,所有的格式,以便转换为另一种格式是更小的痛苦。 Assimp是可扩展的。因此你可以导入你的专有格式,但仍不能修改code。 其他4: Assimp是开源!我们支持开源软件! Assimp has support for any popular format you can imagine. It has a unified interface for all formats so that switching to another format is less of a pain. Assimp is extensible. You can thus import your proprietary format and still not modify your code. ADDITIONAL 4: Assimp is open source! Let's support open source software!