欢迎访问《图学学报》 分享到:

图学学报 ›› 2022, Vol. 43 ›› Issue (3): 478-485.DOI: 10.11996/JG.j.2095-302X.2022030478

• 计算机图形学与虚拟现实 • 上一篇    下一篇

融合阴影图和深度划分阴影体的阴影渲染算法

  

  1. 长春理工大学计算机科学技术学院,吉林 长春 130022
  • 出版日期:2022-06-30 发布日期:2022-06-28
  • 基金资助:
    国家自然科学基金项目(U19A2063),吉林省科技发展计划项目(20190302113GX)

Algorithm of rendering shadows with combined use of shadow map and deep partitioned shadow volumes

  1. School of Computer Science and Technology, Changchun University of Science and Technology, Changchun Jilin 130022, China
  • Online:2022-06-30 Published:2022-06-28
  • Supported by:
    National Natural Science Foundation of China (U19A2063), Jilin Provincial Development Program of Science and Technology
    (20190302113GX)

摘要:

阴影图算法可以简单、快速地渲染硬阴影,但该算法渲染的硬阴影会在边缘区域出现锯齿状走样。受此影响,基于阴影图算法渲染的柔和阴影,在小尺寸半影区域依然可能会出现锯齿状走样。因此,要渲染无走样的柔和阴影,需要精确计算阴影边缘区域的着色点对点光源的可见性。深度划分阴影体算法可以精确地计算着色点对点光源的可见性,但其不仅在效率上不及阴影图算法,还无法实现柔和阴影渲染。针对上述问题,提出一种融合阴影图和深度划分阴影体的阴影渲染算法,对处于阴影边缘区域的着色点,使用深度划分阴影体算法精确计算该着色点对点光源的可见性;对其他着色点,使用阴影图算法快速计算该着色点对点光源的可见性。最后,将着色点的可见性值存储在可见性图中并滤波即可实现无走样柔和阴影的渲染。

关键词: 阴影图算法, 深度划分阴影体算法, 硬阴影, 柔和阴影, 融合阴影渲染算法

Abstract:

The shadow map algorithm can render hard shadows easily and quickly, but the hard shadow rendered by this algorithm will appear aliased in the edge area of the shadows. Affected by this, the soft shadows rendered based on the shadow map algorithm may still appear aliased in the shadow's small penumbra areas. Therefore, to render soft shadows without aliasing, it is necessary to calculate the visibility of shading points at the edge of the shadow from the point light source precisely. While deep partitioned shadow volumes algorithm can accurately calculate the visibility of the shading point to the point light source, they are less efficient than shadow map algorithms and cannot render soft shadows. In response to the above problems, we propose a shadow rendering algorithm that combines a shadow map algorithm with a deep partitioned shadow volumes algorithm. For the shading points in the shadow edge area, the deep partitioned shadow volumes algorithm is used to calculate the visibility of the shaded point to the point light source accurately, for other shading points, we use the shadow map algorithm to calculate the visibility of the shaded point to the point light source quickly. At last, we store the visibility value of the shading point in the visibility map and filter to achieve the rendering of soft shadows without aliasing.

Key words: shadow map algorithm, deep partitioned shadow volumes algorithm, hard shadows, soft shadows, fusion
shadow rendering algorithm

中图分类号: