DirectX 11 上的 NURBS?

发布于 2024-09-26 04:40:52 字数 241 浏览 4 评论 0原文

可以使用 DirectX 11 在 GPU 上渲染 NURBS 吗?我一直在研究渲染此类曲面的当前趋势,但我在 NURBS 上没有看到任何内容。

我找到了一些相关的参考文献,但没有任何可靠的参考文献......比如 Charles Loop 和 Scott Schaefer 的“Approximating Catmull-Clark Subdivision Surfaces with Bicubic Patches”。

    -

Can you render NURBS on the GPU with DirectX 11? I've been reading up on current trends to rendering surfaces like these, but I don't see anything on NURBS.

I found some related references, but nothing solid... like "Approximating Catmull-Clark Subdivision Surfaces with Bicubic Patches" by Charles Loop and Scott Schaefer.

    -

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

柒夜笙歌凉 2024-10-03 04:40:52

DirectX SDK中有2个演示; SubD10、SubD11 分别用于 DirectX 10/11 实现本文中描述的技术。

There are 2 demos in the DirectX SDK; SubD10, SubD11 for DirectX 10/11 implemenations respectively of the techniques described in this article.

梦过后 2024-10-03 04:40:52

快速回答是否定的。 NURBS 非常复杂,编写一个可以在 GPU 上渲染它们的高效着色器是很困难的。我认为这是可能的,但通常不会这样做,因为有更好的方法。

更好的方法是直接在 GPU 上渲染 Bézier 面片,因为任何 NURBS 都可以转换为一组连接的 Bézier 面片。为了生成补丁,您需要在每个结处执行结插入,直到它达到与度数相同的重数;例如,在立方 NURBS 上,您将在每个结处执行结插入,直到每个结都是三重结。然后,NURBS 的控制点可以被视为连接的贝塞尔网格。

这存在一个特定于着色器的问题:当您对 Bézier 面片进行三角测量时,共享边界的面片也共享完全相同的曲面细分设置至关重要,否则由于曲面细分不匹配,NURBS 曲面中会出现裂纹。如果您使用固定的曲面细分设置,这不是问题,但如果您使用依赖于视图的曲面细分,则需要确保每个面片边界都有独立计算的“视图相关”曲面细分,以便相邻面片匹配。

The quick answer is no. NURBS are pretty complex, and it would be difficult to write an efficient shader that can render them on the GPU. I think it's possible, but it isn't usually done because there's a better way.

The better way is to render Bézier patches directly on the GPU, since any NURBS can be converted into a connected set of Bézier patches. To generate the patches, you perform knot insertion at every knot until it hits the same multiplicity as the degree; e.g. on a cubic NURBS, you would perform knot insertion at every knot until every knot is a triple knot. The control points of the NURBS can then be treated as a connected Bézier mesh.

There is a problem with this, specific to shaders: When you triangulate your Bézier patches, it's critical that patches which share a boundary also share the exact same tessellation settings, or there will be cracks in your NURBS surface due to tessellation mismatch. If you use fixed tessellation settings, this isn't a problem, but if you use view-dependent tessellation, then you need to make sure that each patch boundary has its "view dependent" tessellation calculated independently, so that adjacent patches will match.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文