使用开源OpenCTM进行常用三维格式互导

1. 支持导入的三维格式有:

OpenCTM(.ctm)、Stanford triangle format(.ply)、Stereolitography(.stl)、3D Studio(.3ds)、COLLADA(.dae)、

Wavefront geometry file(.obj)、LightWave object(.lwo)、Geomview object file format(.off)

2. 支持导出的三维格式有:

OpenCTM(.ctm)、Stanford triangle format(.ply)、Stereolitography(.stl)、3D Studio(.3ds)、COLLADA(.dae)、

Wavefront geometry file(.obj)、LightWave object(.lwo)、Geomview object file format(.off)、VRML 2.0(.wrl)

3. 纹理贴图格式:JPEG、PNG

4. 使用命令行工具ctmconv.exe进行批量转换

示例:ctmconv Infinite-Level_02.3ds Infinite-Level_02.obj

详细参数如下:

Usage: ctmconv infile outfile [options]

Options:

Data manipulation (all formats)
--scale arg Scale the mesh by a scalar factor.
--upaxis arg Set up axis (X, Y, Z, -X, -Y, -Z). If != Z, the mesh will
be flipped.
--flip Flip triangle orientation.
--calc-normals If the source file does not contain any normals, calculate
them.
--no-normals Do not export normals.
--no-texcoords Do not export texture coordinates.
--no-colors Do not export vertex colors.

OpenCTM output
--method arg Select compression method (RAW, MG1, MG2)
--level arg Set the compression level (0 - 9)

OpenCTM MG2 method
--vprec arg Set vertex precision
--vprecrel arg Set vertex precision, relative method
--nprec arg Set normal precision
--tprec arg Set texture map precision
--cprec arg Set color precision

Miscellaneous
--comment arg Set the file comment (default is to use the comment
from the input file, if any).
--texfile arg Set the texture file name reference for the texture
(default is to use the texture file name reference
from the input file, if any).

Supported file formats:

OpenCTM (.ctm)
Stanford triangle format (.ply)
Stereolithography (.stl)
3D Studio (.3ds)
COLLADA 1.4/1.5 (.dae)
Wavefront geometry file (.obj)
LightWave object (.lwo)
Geomview object file format (.off)
VRML 2.0 (.wrl) - export only

 

更多请参考:http://openctm.sourceforge.net/

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值