1

我正在尝试使用 Three.js 制作戒指的 3D 模型(就像你戴在手指上的戒指,只是一个圆形戒指)。

我想我可以使用管几何类/对象:

https://github.com/mrdoob/three.js/blob/master/src/extras/geometries/TubeGeometry.js

查看源代码似乎我需要这些参数:

path, segments, radius, radiusSegments, closed, debug

唯一强制性的是路径。但是,我不知道如何设置路径:

https://github.com/mrdoob/three.js/blob/master/src/extras/core/Path.js

http://mrdoob.github.com/three.js/docs/57/#Reference/Extras.Core/Path

http://mrdoob.github.com/three.js/docs/57/#Reference/Extras.Core/CurvePath

是否有任何教程、文档或代码片段可以教我如何设置路径?

If there's anything else you can send me to guide me in making a 3D model of a ring, that would be greatly appreciated. I'm not even sure if using the tube geometry class/object would work, but that's just my first try at it.

Thank you for your time and take care!

Update: Using TorusGeometry, I've got this: Default Torus

I'm still working on moving the object around so I can see the other "sides" of the object, but was wondering if it's possible to "flatten" the outer and inner walls of the Torus. I'll post another question and link to it from here if I can't figure out how to view the torus and "flatten" the inner/outer walls.

Thanks again for looking!

4

1 回答 1

4

It is easier than that.

THREE.TorusGeometry( radius, tubeRadius, radialSegments, tubularSegments )
于 2013-03-30T00:47:35.493 回答