欢迎学习这篇关于CINEMA4D的文章,以下是本文内容。
Introduction介绍
Tessellation is a computer graphics technique that can make a coarse, low-polygonmesh render smooth. This is achieved through polygonal subdivision, which happens at render-time. Working with low-polygon meshes and letting Redshift do the subdivision during rendering has certain advantages:
Tessellation(镶嵌细分)是计算机图形学中的一种技术。低模通过细分,能够渲染成原话的高模。使用低模在3D软件中操做,让Redshift渲染器在渲染时将它们细分,有几个好处:
1、Low-polygon meshes can be simpler to manage for animation reasons
低精度模型好做动画,不卡。
2、The 3D program itself doesn’t have to maintain large numbers of polygons which can be expensive in terms of system memory
在3D软件中假如使用高模,会占用很多内存。
3、It can be more memory-efficient (which is important for GPUs) when combined with view-dependent and/or adaptive subdivision. Small or distant objects, for example, can render smooth with fewer subdivisions.
假如与View-Dependent(仅细分视野范畴内物体)或者Adaptive Subdivision(自适应细分)技术相结合,渲染效率更高(出格是对于GPU渲染而言)。这时,假如物体很远或者很小,只需要使用很低的细分级别。
Redshift subdivides quad polygons using the Catmull-Clark algorithm. For triangles, it uses the Loop algorithm. Redshift supports both screen-space and world-space adaptive tessellation for improved memory usage.
Redshift使用Catumll-Clark算法细分四边面。使用Loop算法细分三角面。为了进步内存使用效率,Redshift同时撑持使用屏幕空间和世界坐标空间来自适应Tessellation。
Displacement is a technique typically combined with tessellation. It allows the user to add extra detail on their meshes through shader networks, i.e. textures, noise shadernodes, etc.
Displacement通常要结合Tessellation技术。用户通过给材质连接贴图或者噪波节点等,来给多边形物体增加更多细节。
The benefits of displacement include: 使用Displacement有两个好处:
1、Manipulating textures and shader networks for certain displacement effects (such as a brick wall) is much easier than manipulating lots of vertices in a 3D program
在3D软件中修改贴图和程序纹理比修改模型点更便利一些。
2、Sculpting apps like ZBrush and Mudbox are easier to use compared to polygon modeling when creating organic geometry. A displacement (or vector displacement) map allows this sculpted detail to be applied on a fairly low-resolution mesh.
在外理生物几何外型的时候,用ZBrush和Mudbox一类的雕刻软件要比用多边形东西容积很多。使用Displacement或者Vector Displacement(矢量置换贴图)能在很低精度的模型上实现很多细节。
3、Because displacement can happen on adaptively tessellated meshes, it can be more memory efficient than using a full-detail, full-tessellation mesh in memory at all times and irrespective of its size or viewpoint.
因为Displacement能够被应用在渲染细分模型上,因而无论对像大小以及不雅察看视角,相比间接使用高精度高细节的模型,使用渲染时在线细分能更节省内存和渲染时间。
Redshift supports both heightfield (displacing along the vertex normal) and vector displacement maps. The vector displacement maps can be in object or tangent space. Importantly, any displacement detail that couldn’t be represented given the existing tessellation settings is represented, instead, using bump mapping – therefore a good level of surface detail can be present even in fairly low-quality tessellation settings.
Redshift撑持Heightfield(高度场,沿Vertex点的发现置换)和Vector Displacement贴图。Vector Displacement贴图能够用物体空间,也能够用切线空间。重要的是,任何当前细分无法到达的细节还能够通过Bump贴图来暗示。因而即即是一些非常小的细节,照旧能够浮现如今相对照较低的细分级别上。
How To Enable In Maya 在Maya中怎样使用
If you don’t care about adaptive tessellation or displacement and prefer to work with Maya’s “Smooth Mesh” properties, you can!
假如你不想用Adaptive Subdivision或者Displacement的话,用Maya的Smooth Mesh属性就行。
If, on the other hand, you docare about adaptive tessellation and/or displacement, you’ll need to use the Redshift-specific tessellation/displacement properties. You have two options for that.
但是,假设你想用Adaptive Tessellation或者Displacement,你能够使用Redshift定制的Tessellation/Displacement属性。你有两种选择。
The easiest way is to use the object’s Redshift properties, as shown below.
最简单的方式是用物体的Redshift属性,如下所示。
Please note that once you enable Redshift’s tessellation, the equivalent Maya Smooth Mesh options will be overridden by the Redshift ones!
请注意,一旦打开了Redshift的Tessellation,与其等价的Maya Smooth Mesh选项就会被屏蔽。
Or, alternatively, you can create a “Redshift Mesh Parameters” node for your mesh(es). You do that through the menu Redshift -> Object Properties -> Create mesh parameter node for selection.
另一种方式是在一个或几个物体上创建一个Redshift Mesh Parameters节点。你能够选择菜单栏的Redshift -> Object Properties -> Create mesh parameter node for selection.
The benefit of this method is that you can use a single mesh parameter node for a hierarchy/group of objects, which is useful when multiple objects need to share the same tessellation/displacement options.
这种方式的长处是,用一个参数就能够控制所有层级或者组中的物体。当有很多物体需要设置不异的Tessellation/Displacement参数时,这非常有用。
Tessellation Settings (镶嵌细分)设置
Subdivision Rule 细分规则
Redshift supports two different algorithms for polygon subdivision: “Loop”, which is used for triangles and “Catmull-Clark”, which is used for quads. These algorithms are also called “Subdivision Rules”.
Redshift撑持两种不同的多边形细分算法:Loop用于三角面细分;Catmull-Clark用于边面细分。这两种算法都在Subdivision Rules中调用。
The “CC+Loop” subdivision rule uses Catmull-Clark for quads and Loop for triangles. On the other hand, the “CC Only” option uses Catmull-Clark for triangles too, by first splitting each triangle into three quads. The “CC Only” mode should be used when Redshift is combined with other software that doesn’t support Loop subdivision.
CC+Lopp细分规则就是在四边面和三角面中调用相应算法。而CC only的意思是先将三角面分成三个四边面,然后调用Catmull-Clark算法细分。CC Only形式应该用于那些不撑持Loop细分的软件。
Screen Space Adaptive屏幕空间自适应
Enabling screen-space adaptive tessellation means that objects that are further away from the camera will be subdivided less and will, therefore, use fewer polygons and less GPU memory. If this option is disabled, then subdivision becomes “world space adaptive”. This option affects the unit used for the “minimum edge length” setting, as explained below.
开启Screen-Space Adaptive(屏幕空间自适应)Tessellation意味着远离摄像机的物体细分级别少一些,这能减少多边形数量,并节省GPU显存。假如关闭这个功能,就酿成了World Space Adaptive(世界空间自适应)。此时Minimum Edge Length(最小边长)设定的单元将起做用。后面会对此进行解释。
Smooth Subdivision平滑细分
This controls whether Redshift should subdivide quads and triangles using the Catmull-Clark and Loop algorithms respectively or whether it should do a simple linear subdivision instead. If you are adding displacement on simple angular meshes (such as walls or a box) and don’t want them turned into smooth, curvy objects, disabling smooth subdivision might be the right option for you.
用于指定能否允许Redshift细分时针对四边面和三角面调用Catmull-Clark和Loop两种不同的细分方式。假如允许,则调用简单的线性细分方式。假如想给一个简单的三角面物体(好比墙或者盒子)增加Displacement,但不想让他们在细分的时候失却棱角,那么关掉Smooth Subdivision是最好的方案。
Minimum Edge Length最小边长度
Adaptive subdivision keeps dividing quads/triangles while their edges are longer than this setting. If you are using screen-space adaptive subdivision, this length is measured in screen pixels. If you are not using screen-space adaptive subdivision, this means “world space adaptive subdivision” so the length is measured in world-space units. The smaller this value, the more tessellation will be applied to the mesh. If you set the value to zero, tessellation will continue until “maximum subdivisions” (see below) has been reached.
在Adaptive Subdivision时,假如几何体形关的边沿比设定值长,细分就会持续下云。假如使用屏幕空间Adaptive Subdivision,那么这个值的长度单元就是像素。假如使用的不是屏幕空间Adaptive Subdivision,那细分形式就是World Space Adaptive Subdivision(世界空间自适应细分),此时长度则是使用世界空间单元。此时这个值越小,应用在模型上细分级别就越多。假如设定值为0,则细分会一直进行,直至到达Maximum Subdivision最大细分设定值。
Maximum Subdivisions最大细分
Subdivision happens in ‘passes’. Each pass can turn single quad/triangle into 4 quads/triangles respectively. This means that the number of polygons can grow extremely quickly with this option. It is a “power of four”.
细分会一级一级的进行。每级细分城市把单个四边/三角面继续细分成4个四边/三角面。这意味着多边形的数量增长很快。它是以4个底的指数速度增长。
- A setting of 1 can turn 1 quad into 4 quads 设定1则最高将1个四边面分成四个四边面
- A setting of 2 can turn 1 quad into 16 quads 设定2最高将1个四边面分成16个四边面
- A setting of 3 can turn 1 quad into 64 quads 设定3最高将1个四边面分成64个四边面
- A setting of 4 can turn 1 quad into 256 quads 设定4最高将1个四边面分为256个四边面
- A setting of 5can turn 1 quad into 1024 quads 设定5最高将1个四边面分为1024个四边面
- A setting of 6 can turn 1 quad into 4096 quads 设定6最高将1个四边面分为4096个四边面
- A setting of 7can turn 1 quad into 16384 quads 设定7最高将1个四边面分为16384个四边面
- A setting of 8can turn 1 quad into 65536 quads 设定8最高将1个四边面分成65536个四边面
So a mesh containing only 1000 quads, using a “minimum edge length” of 0.0 and a “maximum subdivisions” 8, could become a 65 millionquad mesh (!) which could take a long time to generate and would consume lots of memory! For this reason, great care has to be applied when adjusting both “maximum subdivisions” and “minimum edge length”.
因而,一个1000个面的模型,使用Minimum Edge Length为0,Maximum Subdivision为8,可能会被细分成6500万面,这会花费大量的细分时间,且占用大理的显存空间。所以,在调整Minimum Edge Length和Maximum Subdivisions 的时候,都要出格小心。
Out-Of-Frustum Tessellation Factor 视野外细分
This option allows objects that outside the camera frustum (i.e. object that are not directly visible to the camera) to be tessellated to a lesser degree. The larger this value, the lesser the tessellation will be. This setting can help save a lot of memory by tessellating “unimportant” objects less. However, sometimes an object might be outside the camera frustum but still very clearly visible through reflections. Or it might be casting a well-defined shadow within the camera frustum. For these key objects, smaller numbers should be used. A setting of 0.0 disables this optimization.
这个参数用于指定相机视野之外的物体怎样减少细分级别。数量越大,细分级别就越低。通过减少不重要物体的细分级别,使用这个参数能大量节省显存。但视野外的物体有时却可能出如今明晰的反射中,有时则投射出完好的阴影外形。此时,就不能将参数设置得过大。数值0.0暗示不用优化调整。
Displacement Settings置换设置
Maximum Displacement最大置换
This parameter tells Redshift what is the maximum length the displacement shaders/textures will be displacing the vertices by. For example, if you’re adding two displacement textures in the shader graph and each displacement texture can push the vertices by 1 unit, then both of them can push the vertices by a maximum of 2 units, so a setting of 2.0 should be used for this setting. Unfortunately, due to flexible nature of shaders, it’s not currently possible to compute this value automatically. Settings similar to this can be found on other renderers, too. They might be called “bounds padding” or “min/max bound”.
这个参数用于限制Redshift Displacement模型的最大位移长度。假如你为材质连接了两个Displacement贴图,每个城市将模型挪动一个单元,两个叠加则可能会将模型点挪动两个单元。此时的Maximum数值就要设为2。但为了简单,目前着器自己其实不主动计算这个值,类似的设定参数在其它渲染器中也有,只不外名字不同,如Bounds Padding或者Min/Max Bound之类。
If the value for this setting is set too low, you will see a ‘ceiling’ on your displacements, i.e. the maximum displacement will be clamped.If, on the other hand, this value is set too high, there won’t be any visual artifacts but the performance could suffer.It is, therefore, advisable to use a value that is as low as possible before seeing any artifacts.
假如这个值设置太低,模型上就可能呈现类似于“触碰天花板”的现像。最大Displacement有可能被剪切掉一块。另一层面,假如这个值太大,虽然没有Displacement错误,但是可能会牺牲渲染效率。因而,在包管没有Displacement位移呈现问题的前提下,这个值设置的尽可能的小。
Displacement Scale置换缩放
This scales the displacement results, which has the effect of accentuating or toning down the displacement. While it is possible to scale the displacement in the shader graph itself, this setting was added for the case where the same displacement shader is used on different meshes but different levels of displacement ‘strength’ are required among these meshes.
这个参数将缩放Displacement成果。能够通过它来增大或者缩小Displacement效果。虽然能够通过添加节点来缩放置换。但增加这个参数的目的是,能够在需要不同缩放值的物体上单独设定置换缩放,从而让它们都能够一并使用一个置换贴图。
Enable Auto Bump Mapping开启主动增加凹凸效果
This essential option allows you to catch high frequency lighting detail that would otherwise be missed by the tessellated displaced geometry. It emulates what would happen if you were to tessellate your geometry to a sub-pixel level and modifies the surface normals accordingly, as if they were bump-mapped.
使用这个选项,能够将很小的光影细节渲染保留下来。因为受细分级别所限,置换可能会漏掉很多外表细节。然而使用这个参数后,相当于在渲染过程中,不只要考虑模型的置换,还要考虑法线的变革。简单的说,就是在置换的根底中加上凹凸贴图。
How To Use Displacement 怎样使用置换
After configuring the tessellation settings, the displacement shader should be set. Please click here for more information.
在细分设置完后,连接好Displacement节点。
UV Smoothing平滑调整UV
When “Smooth subdivision” is enabled, Redshift will smooth not only the vertex positions but also the UV coordinates and tangent space vectors. Smoothing UV coordinates means that the UVs will be shifted to remove any ‘zig-zagging’ and ‘UV breaks’during tessellation and maintain smooth UV-space curves. In the majority of cases, this is the desirable way to treat UVs. However, there are cases where strict UV layouts (such as with when UV tiles are aligned to quads) need to be preserved and not smoothed.
当Smooth Subdivision开启时,Redshift不只会平滑点的位置,也会平滑调整UV点坐标以及相应切线空间的向量。Smooth UV意味着细分时调整点的UV坐标位置,以消除“Zig-Zagging”(锯齿问题)和UV Breaks(UV不持续问题)从而在细分的同时连结UV的平滑。大部门条件下,这种处置UV的方式符合需求。但也有一些对UV位置要求很严格的条件(好比UV分块以矩形整齐布列)。此时,就需要连结点的UV不变,不能做调整。
For this reason, Redshift supports enabling/disabling UV smoothing:
基于上述原因,Redshift能够设定开启/关闭UV Smoothing:
In Maya, Redshift uses the “Smooth UVs” attribute which belongs to the shape’s Smooth Mesh ->Extra Controls set of attributes.
在Maya中,能够先进入每个物体的Shape节点,在Smooth Mesh ->Extra Controls中找到Smooth UVs。 |
|