10 Fun Things to do with Tessellation

原文地址:http://castano.ludicon.com/blog/2009/01/10/10-fun-things-to-do-with-tessellation/

Hardware tessellation is probably the most notable feature of Direct3D11.

Direct3D11 was announced at the last Gamefest and a technical preview was released in theNovember 2008 DirectX SDK. Hardware implementations are expected to be available this year.

Direct3D11 extends the Direct3D10 pipeline with three new stages: Two programmable shader stages (the Hull and Domain Shaders), and a fixed function stage (the Tessellator). More details can be foundhere and here.

Rendering of Catmull-Clark subdivision surfaces is often mentioned as the primary application for the tessellation pipeline, but there are many other interesting uses that have not received that much attention.

I thought it would be interesting to take a closer look at those other applications, and submitted a proposal to do that at GDC’09. However, it seems that the organizers do not think tessellation is as interesting as I do, or they didn’t like my proposal, or maybe it’s just that they know I’m a lousy speaker. I will never know, because the gracious feedback of the GDC review committee can be represented by a single boolean.

In any case, here’s a brief overview of the 10 fun things that I was planning to talk about. I don’t get very deep into the technical details, but in future posts I may describe some of these applications more thoroughly. Please, leave your comments if there’s something you would like to learn more about.

PN-TRIANGLES

Curved PN Triangles is a triangle interpolation scheme that operates directly on triangle meshes whose vertices are composed of positions and normals (PN stands for Point-Normal).

It’s an interesting way of improving visual quality that offers a simple migration path, since assets do not need to be heavily modified.

The PN Triangle evaluation consists of two steps: First, for every triangle of the input mesh a triangular cubic patch is derived solely from the vertex positions and normals; no adjacency information is required. Then, the resulting patch is subdivided or tessellated for rendering.p>

The resulting surface is smoother than the polygonal surface, but does not have tangent continuity in general, and that results in shading discontinuities. To hide these discontinuities normals are interpolated independently using either linear or quadratic interpolation. These normals are not the true surface normals, but they provide a smooth appearance to the surface.

This two-step evaluation maps very well to the Direct3D11 tessellation pipeline. The evaluation of the control points can be performed in the Hull Shader, the fixed function tessellator can produce a tessellation pattern in the triangle domain, and the actual surface can be evaluated for each of the tessellated vertices in the Domain Shader.

In order to support sharp edges a rim of small triangles is added along the edges. That increases the number of patches, and it’s not entirely clear how to properly texture map them.Scalar Tagged PN-Triangles solves that problem in a more elegant way by tagging each crease vertex with three scalar that act as shape controllers and modify the construction of the surface control points. However, this representation does not support crease corners.

SILHOUETTE REFINEMENT

When tessellation is enabled the only supported primitive type is the patch primitive. In Direct3D11 a patch is an abstract primitive with an arbitrary number of vertices. You can use patches to represent traditional primitives (ie. a triangle is just a patch with 3 vertices), but this also enables you to represent other input primitives with arbitrary topology and additional connectivity information.

An interesting extension of of PN-Triangle tessellation is to augment the input triangles with the neighbor vertices in order to perform silhouetterefinement.

With this additional information it’s possible to compute tessellation factors in he Hull Shader based on whether an edge is on the silhouette or the interior of the mesh. Then the fixed function tessellator uses these edge tessellation factors to produce a semi-regular tessellation pattern and the Domain Shader transforms it to interpolate the surface.

PHONG TESSELLATION

Phong Tessellation is a geometric version of Phong interpolation, but applied to vertex positions instead of normals.

First, points are interpolated linearly over each triangle using its barycentric coordinates, then the points are projected onto the planes defined by the corner position and normal, and finally the result of the three projections is interpolated again.

This procedure produces a smooth surface comparable to PN Triangles, but its evaluation is much cheaper, since no additional control points need to be computed.

BEZIER SURFACES

Curved surfaces are not only useful for characters, but also for level geometry and objects.

id Software introduced the use of quadratic Bezier patches for architectural geometry in Quake 3 Arena and has been using them ever since.

Climax Brighton’s Moto GP used cubic Bezier patches to model the motorcycles.

Bezier patches can be evaluated very efficiently, because they don’t need any information about the surrounding mesh. As these games show, tessellation hardware is not required to render these surfaces. However, hardware tessellation will allow doing it much more efficiently, and will facilitate the use of these and more complex surfaces.

APPROXIMATION TO SUBDIVISION SURFACES

Rendering of approximated Catmull-Clark subdivision surfaces is probably the most anticipated application of hardware accelerated tessellation. Several approximation methods exist.

Approximating Catmull-Clark Subdivision Surfaces with Bicubic Patches is the most popular one. This approximation constructs a geometry patch and a pair of tangent patches for each quadrilateral face of the control mesh. The geometry patch approximates the shape and silhouette, but does not provide tangent continuity. A smooth normal field is constructed using two additional tangent patches. The approximation supports boundaries and has also been extended to support creases in Real-Time Creased Approximate Subdivision Surfaces.

GPU Smoothing of Quad Meshes proposes an alternative approximation using piecewise quartic triangular patches that have tangent continuity and do not require additional tangent patches to provide a smooth appearance. In Fast Parallel Construction of Smooth Surfaces from Meshes with Tri/Quad/Pent Facets the same approach is extended to approximate triangular and pentagonal faces.

Kenneth Scott, id Software

Gregory patches are a more compact representation that also provides a very similar approximation, but only support quad and triangle control faces.

The availability of sculpting tools like ZBrush and Mudbox makes it possible to create highly detailed meshes. Displaced subdivision surfaces provide a compact and efficient representation for these meshes.

RENDERING GEOMETRY IMAGES

Another approach to render highly detailed surfaces is to use geometry images. While geometry images can be rendered very efficiently, their video memory requirements are generally higher than displacement maps due to the lack of high precision texture compression formats. Traditional animation algorithms are not possible with this representation, and view dependent tessellation level evaluation is complicated, because geometry information is not directly available at the Hull Shader stage. However, geometry images may be the fastest approach to render small static objects at fixed tessellation levels.

TERRAIN RENDERING

Terrain rendering is one of the most obvious applications for tessellation. The flexibility of the tessellation pipeline enables the use of sophisticated algorithms to evaluate the level of refinement of the terrain patches, and frees you from having to worry about many of the implementation details.

It’s also possible to extend traditional terrain engines with arbitrary topologies. Some MMORPGs are already doing that to create more rich environments.

For example Saga of Ryzom, a game that is based on the Nevrax engine, uses cubic patches to model the terrain, which enables them to create impressive cliffs and overhangs.

Tessellation should make it possible to combine regular heightfields, with caves, cliffs, arches, and other interesting rock formations.

I think that ZBrush or Mudbox would be excellent tools to create natural looking rugged terrain.

HAIR RENDERING

Efficient hair rendering is one of the most interesting applications of the Direct3D11 tessellation pipeline. In addition to triangular and quad patches the fixed function tessellator can also generate lines, which are very useful for applications like hair and fur rendering.

The algorithm described in Hair Animation and Rendering in the Nalu Demo maps very well to the tessellation pipeline.

As shown in Real-Time Rendering of Realistic Hair, the use of the hardware tessellation pipeline makes it very easy to simulate and render realistic hair with high geometric complexity in real-time.

That’s possible, because the simulation is performed only on a few hundred guide hairs, that are expanded by the tessellator into thousands of hair strands.

RENDERING PANORAMAS

Another application for tessellation is to perform arbitrary non linear projections, that is useful, for example, to create real-time panoramas.

Since graphics hardware relies on homogeneous linear interpolation for rasterization, arbitrary projections and deformations at the vertex level result in errors unless the surface is sufficiently refined.

The traditional image based approach is to render the scene to a cube map and then perform an arbitrary projection of the cubemap to screenspace relying on texture hardware to do the sampling and interpolation. This was the approach taken in Fisheye Quake and Pan quake.

While that works well, it requires rendering the scene to the 6 cube faces, and sometimes results in oversampling or undersampling of some areas of the scene.

Dynamic Mesh Refinement on GPU using Geometry Shaders proposes the use of the geometry shader to dynamically refine the surfaces to prevent linear interpolation artifacts. However, the Geometry Shader operates sequentially and is not well suited for this task. On the other side, the dynamic mesh refinement algorithm maps well to the Direct3D11 tessellation pipeline.

RENDERING OF 2D CURVED SHAPES

While GPUs can render simple polygons, they are not able to automatically handle complex concave and curved polygons with overlaps and self intersections, without prior triangulation and tessellation.

The Direct3D11 tessellation pipeline is not designed to perform triangulation. However, there’s a well known method to render arbitrary polygons using the stencil buffer that can be used in this case. This method was first described in theOpenGL Red Book, but was recently popularized by its implementation in the Qt graphic library.

It’s possible to combine this technique with hardware tessellation to render curved tessellated shapes without the need of expensive CPU tessellation and triangulation algorithms.

posted @ 2013-04-01 00:18 麒麟子(Alex) 阅读(...) 评论(...) 编辑 收藏

10 Fun Things to do with Tessellation相关推荐

  1. Surface Shaders with DX11 / OpenGL Core Tessellation 表面着色的曲面细分 - Unity Shader Reference 系列5

    Surface Shaders with DX11 / OpenGL Core Tessellation DX11/OpenGL核心下表面着色器的曲面细分 本文档主要是对Unity官方手册的个人理解与 ...

  2. Unity URP 曲面细分

    Unity URP 曲面细分 我终于变得不像我 文章目录 Unity URP 曲面细分 1 曲面细分与镶嵌 1.1 外壳着色器 Hull Shader 1.2 镶嵌器阶段 Tessellator 1. ...

  3. H3CNE最新版官网考试模拟题库

    以下工作于OSI 参考模型数据链路层的设备是__A____.(选择一项或多项) A. 广域网交换机 B. 路由器 C. 中继器 D. 集线器 A 数据链路层传输的是帧,交换机是基于帧转发的:B 路由器 ...

  4. Tessellation (曲面细分) Displacement Mapping (贴图置换)

    DirectX 11 Tessellation (曲面细分)-什么是 Tessellation (曲面细分) ? 它为什么可以起到如此关键的数据? 随着近期人们对 DirectX 11 的议论纷纷,你 ...

  5. 计算机缩写术语完全介绍 By 001pc @ 1997.10.1-2004-6-12

    计算机缩写术语完全介绍By 001pc @ 1997.10.1-2004-6-12 在使用计算机的过程中,你可能会碰到各种各样的专业术语,特别是那些英文缩写常让我们不知所云,下面收集了各方面的词组,希 ...

  6. Direct3D 10系统(二)

    Direct3D 10系统(二) 作者:David Blythe 本文版权归原作者所有,仅供个人学习使用,请勿转载,勿用于任何商业用途. 由于本人水平有限,难免出错,不清楚的地方请大家以原著为准.欢迎 ...

  7. 10年GPU通用计算回顾

    硬件T&L单元催生GPU诞生 前言:从世界上第一款GPU横空出世到今天,显卡已经走过了10年历史.GPU在这10年演变过程中,我们看到GPU从最初帮助CPU分担几何吞吐量,到Shader单元初 ...

  8. Tessellation

    Tessellation 细分曲面技术是AMD(ATI)常年研发多代的技术,经过多年发展最终被采纳成为DX11的一项关键技术,因此历来都是宣传重点.和 光线追踪不同,现在的 光栅化图形渲染技术的核心是 ...

  9. 基于Centroidal Voronoi Tessellation (CVT)算法的点云三角网格化方法

    在之前的博客中,老甘已经跟大家提到过Centroidal Voronoi Tessellation(CVT)算法的实现与可视化. 链接:https://blog.csdn.net/aliexken/a ...

最新文章

  1. php redis 安装和使用
  2. Android开发艺术探索》读书笔记 (8) 第8章 理解Window和WindowManager
  3. 【转载】增强中调用BAPI并COMMIT使用
  4. php 请求url 返回json,php解析请求url并返回json数据
  5. python线程创建对象_Python多线程编程基础:如何创建线程?
  6. python中字符串文件如何打开_python-字符串·文件·集合操作
  7. 作业6--团队项目之需求
  8. 更改Ubuntu终端复制和粘贴的快捷键
  9. 一个很cool的C#的高性能数学库
  10. 利用HOG特征进行人体检测--简述
  11. yii2 mysql 队列_yii2.0 中的队列
  12. php mysql cpu使用率_Mysql CPU占用高的问题解决方法小结
  13. (转)知识图谱如何让智能金融“变魔术”
  14. python怎么读取表格中的数据_如何用Python读取电子表格中的数据,面试必学
  15. CVPR 2021 Pre-Trained Image Processing Transformer
  16. Node.js、npm环境配置与Vue项目创建
  17. Azure 媒体服务可将优质内容传输至 Apple TV
  18. linux系统中开机自启的三种方式
  19. vue——axios请求成功却进入catch的原因
  20. LeetCode--574. 当选者

热门文章

  1. Excel一键导出选区内的图片,非选区不导出
  2. Android中打开扬声器关闭麦克风的代码实现
  3. Android(4.2) Sensors 学习——G-sensor,Gyroscope驱动移植
  4. |- apache -| 手机真机测试之访问本地apache服务器
  5. 经典故事---话说河南人
  6. Excel把文本替换为数字
  7. 关于腾讯csig前端面试
  8. 关于oracle导出的dmp导入失败的问题。提示值过大。oracle修改字符编码集。
  9. Git错误:Incorrect username or password ( access token )
  10. FactoryIO物料分拣系统