节点文献

虚拟环境中阴影的实时绘制算法研究

Research on Real-time Rendering Algorithms of Shading and Shadows in Virtual Environment

【作者】 张威巍

【导师】 游雄;

【作者基本信息】 解放军信息工程大学 , 地图制图学与地理信息工程, 2009, 博士

【摘要】 论文主要研究虚拟环境中不同类型阴影的实时绘制算法,研究的内容包括阴影反走样算法、全方向光源下的阴影绘制方法、基于图像的柔和阴影实时绘制算法、基于图像空间的环境遮挡算法、数字地貌晕渲中的阴影绘制算法。论文的研究工作主要有以下几个方面:第一、分析了标准阴影贴图算法的特点,尤其是对它的几个缺点进行了细致地讨论。通过对阴影贴图算法中走样问题进行定性和定量分析发现,屏幕上的像素对深度纹理采样率不足是导致阴影走样的根本原因,因此改善阴影走样最根本的方法就是提高深度纹理的采样率。分别对基于分割和基于变形的反走样算法进行了研究,总结了它们的特点。无论是在PSSMs算法中,还是在后来提出的Cascaded Shadow Maps算法中,都没有明确给出场景分割的标准,不利于实际操作,为此根据阴影走样的评价方法本文提出了场景的每个分割单元不出现走样的最低标准,得出了场景分割方案和分辨率之间的定量关系,这样从眼睛空间视锥体的近平面到远平面可以通过迭代推进的方式进行合理的分割,提供了一种操作性较强的场景划分方法。第二、根据虚拟地形环境的特点提出了一种视点自适应的阴影算法,该算法能够根据眼睛空间视锥体与地形之间的关系实时计算出光源视锥体应该所包含的最小范围,这样就可以保证最大程度地利用深度纹理。运用全球虚拟地形环境对该算法进行了实验,结果表明该算法能够有效地改善阴影走样现象。本文还讨论了利用Blinn-Newell贴图、球面贴图、立方体贴图、抛物面贴图进行全方向光源阴影绘制的特点,从效果和效率两个方面比较得出抛物面贴图算法最适合全方向光源的阴影绘制。第三、根据理论分析和现实照片对比提出了柔和阴影算法在效果上的评价标准,对利用图像过滤绘制柔和阴影的算法进行了讨论,说明了影响柔和阴影绘制效率和效果的因素。对比了VSM、CSM、ESM三种半影不变的柔和阴影算法,总结了三种算法的优劣。运用实验得出了影响PCSS算法计算效率的主要因素,通过分析发现在PCSS算法中计算遮挡物体空间位置和阴影测试都需要对深度纹理的同一片区域进行采样,这样就造成了对深度纹理的重复采样。论文在此基础上提出了一种优化算法,不仅将两次采样过程合二为一,并且简化了遮挡物体空间位置的计算,在采样过程中当第一次得到满足条件的点时就确定遮挡物体。实验证明该算法既能获得与PCSS算法近似的效果又能有效的提高场景的计算效率,尤其是当场景中的阴影占画面比例较多的时候这种计算效率上的优势更加明显,在同样的场景条件下本算法较PCSS算法提高大约10%的效率。第四、对环境遮挡算法的发展、特征进行了详细的论述,尤其是对近些年人们所提出的优化算法进行了全面的总结和评价。重点对两种基于屏幕空间的环境遮挡算法的原理和特征进行了论述,通过比较认为HSAO算法更具可扩展性。利用实验对HSAO算法的各种影响因素进行了分析,包括:深度纹理采样范围、采样方向数量、射线方向上采样数量、屏幕分辨率和视点方位,得出了这些因素对HSAO算法性能的影响规律,最后讨论了HSAO算法在虚拟环境中的应用及硬件加速方法,并探讨了HSAO算法的优化方法。第五、根据Imhof和施祖辉等专家的晕渲思想总结了传统地貌晕渲中阴影绘制的基本规律,并对常用的几种用于数字晕渲阴影计算的光照模型进行了讨论。从理论和实验两个方面对漫反射光照模型、基于坡向的模型进行了对比,详细评价了它们的优缺点。漫反射模型能够很好的表现平缓地区的特征,但很难对起伏较大地区特征线进行表现,而基于坡向的算法正好相反。本文针对这两个模型的特点给出了四点改进意见,并据此提出一种新的面向地貌因子的光照模型。该模型分别根据坡度、坡向和高程三个要素对顶点的亮度进行计算,能够较好的克服漫反射模型和基于坡向光照模型的缺点。论文还分析了确定光源方位的不同方法,并针对其中的缺点提出了相应的改进措施。

【Abstract】 Different real-time rendering algorithms of shading and shadows are researched in this dissertation. We concentrate on some key technologies, such as anti-aliasing algorithms of shadows based on image, rendering algorithms of shadows under omni directional light source, real-time rendering algorithms of soft shadows based on image, screen space ambient occlusion algorithms, shading algorithms in digital relief shading. The followings are what we have done in this dissertation:Firstly, we analyzed the characters of standard shadow mapping algorithm and talked out the shortcoming of it. Through analyzing aliasing problem of shadow mapping algorithm, it could be found that under-sampling is the main reason of aliasing. So the essential way to improve aliasing of shadows is enhancing the sampling of shadow map. This dissertation summarizes the characters and conditions of algorithm based on partition and warping. A new algorithm was brought forward about partition way in PSSM algorithm. Neither PSSM algorithm nor Cascaded Shadow Maps algorithm has clear partition criterions. We have brought forward furthest criterion of every part of view frustum in eye space according to measure method of shadow aliasing and get ration relationship between split project of view frustum and resolution. This dissertation provides a kind of view split algorithm which could operate easily.Secondly, according to the characters of virtual terrain environment, a new shadow algorithm of viewpoint adapting was brought forward by this dissertation. This algorithm can work out least area which light source view frustum should surround according to the relationship of view frustum in eye space and terrain. By using this algorithm, the shadow map could be utilized greatly. We take an experiment of this algorithm by using global virtual terrain environment. The outcomes of the experiment show that this algorithm can improve the aliasing of shadows. We also disscuss the characters of the rendering algorithms of shadows under omni-directional light source by using Blinn-Newell environment map, spherical environment map, cube environment map and paraboloid environment map. It is could be found that paraboloid environment map is most adapt to shadow rendering under omni-directional light source.Thirdly, evaluating criterion is brought forward according to theory analysis and photos of shadows. We talk out the algorithm which rendering soft shadow using image filtering. The factors of impacting effect and efficiency of soft shadow rendering are showed. VSM, CSM, ESM are compared each other and the characters of these algorithms are summarized. The main factors that affect efficiency of PCSS algorithm is gotten through experiments. We can conclude that the same region of depth map is sampled second time during computing the position of occluder and occlusion testing. So re-sampling is occurred in depth map. Thus we bring forward a soft shadow rendering algorithm which have unfixed penumbras. This algorithm combines the two same sampling to one sampling and predigests the course of computing occluder’s position. This algorithm either gets same effect as PCSS or has higher efficiency. And when the shadows in scene are excessive, the advantages are more outstanding. The experiments show that this algorithm is more efficient than PCSS about 10 percent.Fourthly, this dissertation talks out the development and character of environment occlusion algorithms, especially summarizes the optimized algorithm brought forward recent years. We talk out the principle and characters of two ambient occlusion algorithms. We believe that HSAO algorithm has better expansibility through comparing. Different kinds of factors are analyzed by experimenting, such as sampling region of depth map, number of sampling directions, number of sampling points in radial direction, resolution of screen, orientation of viewpoint. The law that these factors affecting the HSAO is brought by this dissertation. The application of HSAO in Virtual Environment and method of acceleration by using GPU is talked out. The optimizing method of HSAO is discussed in this dissertation.Lastly, basic laws of traditional relief shading are summarized by studying the ideas of Imhof and Shizuhui. Some shading model is talked out which is used commonly in relief shading. Diffuse model and aspect based model is compared by experimenting and theory analyzing. The pros and cons of the two algorithms are analyzed. Diffuse model could render the character of plain terrain greatly and aspect based model is better in representing the rolling terrain. We bring forward four ideas about the two shading models are introduced. A new light model oriented slope, aspect and elevation. It make an experiment on this new light model using a pyramids model which slope increased with elevation and two DEM data which are differently in terrain character each other. It is concluded that this new light model could overcome effectively the drawbacks of Lambert model and aspect-based shading.

节点文献中: 

本文链接的文献网络图示:

本文的引文网络