Blender 3D:各种各样的教程
This article has multiple issues. Please help improve it or discuss these issues on the talk page . ( Learn how and when to remove these messages )
|
Three-dimensional (3D)
computer graphics |
---|
|
Fundamentals |

Gouraud shading
(
/
ɡ
uː
ˈ
r
oʊ
/
goo-ROH
), named after
Henri Gouraud
, is an
interpolation
method used in
computer graphics
to produce continuous
shading
of surfaces represented by
polygon meshes
. In practice, Gouraud shading is most often used to achieve continuous lighting on
triangle meshes
by computing the lighting at the corners of each triangle and
linearly interpolating
the resulting colours for each
pixel
covered by the triangle. Gouraud first published the technique in 1971.
[1]
[2]
[3]
However, enhanced hardware support for superior shading models has yielded Gouraud shading largely obsolete in modern rendering.
::戈劳影 (/ɡuːˈroʊ/ goo-ROH),以亨利·戈劳命名,是计算机图形中用于通过多边形网表现的表面的连续影色的插入方法.在实践中,戈劳影最常用于通过计算每个三角形的角落的照明并线性插入三角形所覆盖的每个像素的结果颜色来实现三角形网的连续照明.戈劳于1971年首次公布了该技术. [1] [2] [3] 然而,对优质的影色模型的增强硬件支持使得戈劳影在现代染中基本上过时了.
Description
::描述
Gouraud shading works as follows: An estimate to the
surface normal
of each
vertex
in a polygonal 3D model is either specified for each vertex or found by averaging the surface normals of the polygons that meet at each vertex. Using these estimates, lighting computations based on a reflection model, e.g. the
Phong reflection model
, are then performed to produce colour intensities at the vertices. For each
screen pixel
that is covered by the polygonal mesh, colour intensities can then be
interpolated
from the colour values calculated at the vertices.
::戈劳的阴影工作如下:在多边形3D模型中,每个顶点的表面正常值的估计要么为每个顶点指定,要么通过平均每个顶点相遇的多边形的表面正常值来找到.使用这些估计,基于反射模型的照明计算,例如反射模型,然后在顶点进行以产生颜色强度.对于被多边形网覆盖的每个屏幕像素,颜色强度可以从顶点计算的颜色值进行插入.
Comparison with other shading techniques
::与其他遮技术的比较

Gouraud shading is considered superior to
flat shading
and requires significantly less processing than
Phong shading
, but usually results in a faceted look.
::色的阴影被认为优于平面阴影,需要比色处理少得多,但通常会产生面积较大的外观.
In comparison to Phong shading, Gouraud shading's strength and weakness lies in its interpolation. If a mesh covers more pixels in screen space than it has vertices, interpolating colour values from samples of expensive lighting calculations at vertices is less processor intensive than performing the lighting calculation for each pixel as in Phong shading. However, highly localized lighting effects (such as
specular highlights
, e.g. the glint of reflected light on the surface of an apple) will not be rendered correctly, and if a highlight lies in the middle of a polygon, but does not spread to the polygon's vertex, it will not be apparent in a Gouraud rendering; conversely, if a highlight occurs at the vertex of a polygon, it will be rendered correctly at this vertex (as this is where the lighting model is applied), but will be spread unnaturally across all neighboring polygons via the interpolation method.
::与影相比,高罗影的优点和缺点在于其插入.如果网格在屏幕空间中覆盖的像素数量超过它的顶点,则从高峰上的昂贵照明计算样本中插入颜色值比在影中执行每个像素的照明计算要少.然而,高度局部化的照明效果 (如光谱亮点,例如果表面反射光的闪光) 将不会被正确染,如果亮点位于多边形的中间,但不扩散到多边形的顶点,它将不会在高罗染中显现;反之,如果在多边形的顶点发生亮点,它将在这个顶点被正确染 (因为这个模型在所有邻近的多边形中传播光),但将通过插入方法不被应用.
The problem is easily spotted in a rendering which ought to have a specular highlight moving smoothly across the surface of a model as it rotates. Gouraud shading will instead produce a highlight continuously fading in and out across neighboring portions of the model, peaking in intensity when the intended specular highlight aligns with a vertex of the model. While this problem can be fixed by
increasing the density of vertices
in the object, at some point the
diminishing returns
of this approach will favour switching to a more detailed shading model.
::由于光的光在模型的表面上顺利移动,因此很容易发现问题.而Gouraud阴影将会在模型的邻近部分不断地产生光,当预期的光与模型的顶点对齐时,强度达到顶峰.虽然可以通过增加对象的顶点密度来解决这个问题,但在某个时候,这种方法的收益率会减少,这将有利于切换到更详细的阴影模型.
-
A Gouraud-shaded sphere-like mesh - note the poor behaviour of the specular highlight.
::一个高罗影球状网 - - 注意镜面亮点的不良行为. -
Another sphere-like mesh rendered with a higher polygon count
::另一种球状网格呈现出更高的多边形数量
Linear vs. hyperbolic interpolation
::线性与过度波动的插入
Gouraud's original paper described linear color interpolation.
[1]
In 1992, Blinn published an efficient algorithm for hyperbolic interpolation
[4]
that is used in
GPUs
as a perspective correct alternative to linear interpolation. Both the linear and hyperbolic variants of interpolation of colors from vertices to pixels are commonly called "Gouraud shading".
::戈罗的原始论文描述了线性色彩插入.[1] 1992年,布林发表了一种高效的超标插入算法[4],该算法用于GPU作为线性插入的视角正确替代方案.从顶点到像素的色彩插入的线性和超标变体都通常被称为"戈罗阴影".
Mach bands
::马赫频段
Any linear interpolation of intensity causes derivative discontinuities which triggers
Mach bands
, a common visual artifact of Gouraud shading.
::任何强度的线性插入都会导致衍生不连续性,从而触发马赫波段,这是古劳影的常见视觉工件.
See also
::另见
-
List of common shading algorithms
::常见的遮算法列表 -
Blinn–Phong reflection model
::波反射模型 -
Phong shading
::冯氏着色