Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想在three.js中编写一个类似洞的东西。它应该像一个 3x3x3 的立方体,里面有一个 1x1x1 的孔。有没有可能,我首先使用诸如立方体几何之类的东西,然后使用另一个“几何”来删除我想要删除的东西?删除几何?:D
谢谢 :)
如果您希望将事物“切割”成某些形状,您可能会对这篇关于 Constructive Solid Geometry 库的帖子感兴趣。它带有一个用于三个.js 对象的包装器。
它可以让你做这样的事情:
var cube = new CSG.cube(); var sphere = CSG.sphere({radius: 1.3, stacks: 16}); var geometry = cube.subtract(sphere);
=>
这是关于该主题的另一个简短教程。