节点文献

基于GPU优化的三维实时渲染技术的研究

The Research on the 3D Real-time Rendering Optimized Base on GPU

【作者】 毛华庆

【导师】 边馥苓;

【作者基本信息】 武汉大学 , 摄影测量与遥感, 2010, 博士

【摘要】 科学计算可视化、计算机动画及虚拟现实是最近几年来在计算机图形学领域内三大发展方向,其技术核心均为三维真实感图形。当前三维实时渲染技术在军事、航天、航空、医学、地质、勘探、三维游戏和工业计算机辅助设计等方面有着十分广泛的应用。中央处理单元CPU(Central Processing Unit)作为一种通用处理器,要兼顾程序执行和数据运算的并行性、通用性以及它们的平衡性,因此CPU内部大多数的晶体管都用于制造庞大的缓存和复杂的逻辑控制单元,运算单元所占有的比例较小,虽然近年来CPU也出现了多核的产品,不过这样并没有提高晶体管的利用率。与此同时,在游戏产业的推动下,计算机图形处理器(Graphics Processing Unit) GPU的性能正以每年翻倍的速度发展,为了实现更逼真的图形效果,GPU支持越来越复杂的运算,而且在性能上,主流GPU的单精度浮点运算可达到同期CPU的十倍左右,外部存储器带宽为CPU的五倍左右,采用基于GPU计算的构架,所需要的成本和功耗都要优于CPU。而CUDA的问世更克服了许多传统上基于GPU的光线追踪算法所遇到的困难。本文对基于GPU优化的三维实时渲染问题进行了详细的分析,并提出了相应的解决思路和解决方法。主要研究内容包括:GPU三维实时渲染管线的优化处理和并行计算性能优化处理;传统阴影算法及其不足,并对比了光栅化和光线追踪的优缺点。主要工作包括:介绍了GPU的技术框架及其图形渲染管线,包括超长流水线、并行计算、顶点处理器、片元处理器等。并针对GPU与CPU的不同,重点分析和讨论了GPU的加速原理以及当前比较成熟的CUDA通用计算模型构架及其特点。从渲染管线和并行计算两个方面研究了三维实时渲染的优化。在渲染管线方面,分别对渲染管线中常易出现瓶颈的阶段进行了分析,并相应地提出了各个阶段的优化方法。在并行计算方面,以最短时间,在允许误差范围内完成既定的计算任务为优化目标,将重点放在计算的密度和吞吐量上,并总结出在CUDA构架下,并行计算性能优化的三个原则,为实现三维实时渲染系统打下了坚实的理论基础。介绍了阴影的概念及分类,分析了传统基于光栅化的阴影渲染方法和策略,总结了各种阴影算法的不足。采用光线追踪的渲染方式能反映现实世界中光线的多次传播,但其缺点是计算量非常大的,处理计算的时间也较长。为了解决这一不足,本文提出一种基于GPU可并行的PKD-Tree构造算法对三维场景进行划分,以检测光线与场景中物体相交的情况并表现出实时阴影,并给出了与传统KD-Tree计算的比较结果。针对实时三维渲染的重要瓶颈——图形生成速度,本文实现了一个基于GPU的三维实时渲染系统。该系统根据目前图形处理的软硬件体系结构,特别是硬件加速器的图形处理能力,以及图形生成所采用的各种技术对实时渲染进行加速。除此以外,还根据虚拟场景的组织结构和图形生成所需的真实感程度(例如是否产生反射或折射,反射的次数)等因素分析了各种PKD-Tree遍历方法,并详细分析了各种光线二次处理的方法,最后利用递归的方式实现了逼真光效的渲染结果。最后,文章针对未来三维实时渲染技术研究趋势以及研究方向进行了探讨。

【Abstract】 Scientific visualization, computer 3-D (Three dimension) animation and virtual reality are the three major research direction in computer graphics recently, and the core technology is 3D realistic graphics. Current 3D real-time rendering technology is commonly applied in many fields including military, aerospace, aviation, medicine, geology, exploration,3D games and CAD (Computer-aided design) industry etc.CPU (Central Processing Unit) is a general purpose processor, which needs to consider the balance among the program execution, data parallel computing and universality, so most of the transistors in CPU are used for the large cache and complex logic control unit, but the occupation probability of operation unit is very small. Although multi-core CPU products appear, it doesn’t improve the utilization of the transistor. At the same time, propelled by the game industry, GPU (Graphics Processing Unit) performance rate is doubled per year. In order to achieve more realistic graphics effect, more and more complex operations are supported by CPU. The single-precision floating-point operations of the mainstream GPU can reach about ten times performance of CPU in the same period, and the external memory bandwidth is about five times the CPU. GPU computing architecture beats the CPU in the cost and power consumption. As CUDA comes out, it overcomes many difficulties that the traditional GPU-based ray tracing algorithms encountered.This dissertation gives a detailed analysis on 3-D real-time rendering optimization based on GPU and also proposes some effective solutions and suggestions. The main research includes:3-D real-time rendering GPU pipeline optimization methods and parallel computing performance optimization methods; the traditional shadows algorithm; the pluses and minuses of rasteration.The main work and contributions of this dissertation are listed as following:Firstly, a technical framework of GPU and its graphics rendering pipeline are introduced, which includes super pipelines, parallel computing, vertex processor, and fragment processors. For the difference between GPU and CPU, the acceleration principles of GPU are analyzed; and the general-purpose computing model of current mature framework CUDA and its characteristics are discussed. Secondly, parallel computing and rendering pipeline in 3-D real-time rendering optimization are studied. For the rendering pipeline, all the bottleneck stages that often occur in pipelines are analyzed and the optimization methods for all the stages are put forward accordingly. In parallel computing, the optimization goal is to complete the calculation within the allowable error in the shortest time, therefore, calculation density and throughput become the key points, and three parallel computing optimize principles which lay a solid theoretical foundation for 3-D real-time rendering system are summarized in the CUDA architecture.Thirdly, the concept and classification of shadow are introduced, then the strategies of traditional rasterization-based shadow rendering are analyzed and the deficiencies of a variety of shadow algorithms are summarized. Rendering using ray tracing method can reflect the real world, however, the drawback is that the computation is very huge and computing processing is quite long. Therefore, we propose a GPU-based parallel PKD-Tree can be constructed 3-D scene on the division algorithm to detect objects in the scene light and intersection of the situation and demonstrate real-time shadows, and make comparison with the traditional KD-Tree.For the 3-D real-time rendering bottleneck - graphics generation rate, a GPU-based 3-D real-time rendering system is implemented. The system is based on current graphics hardware and software architecture, in particular the graphics capabilities of the hardware accelerator and the graphics are generated by the variety of acceleration. In addition, according to the organizational structure of the virtual scene and graphics realistic levels, the PKD-Tree traversal methods and second light treatment methods are analyzed, after that, the results of realistic light effect using recursively rendering are realized.Eventually, research trends of 3-D real time rendering technology are discussed.

【关键词】 CUDA光线追踪三维实时渲染PKD-Tree
【Key words】 CUDARay Tracing3-D Real-time RenderingPKD-Tree
  • 【网络出版投稿人】 武汉大学
  • 【网络出版年期】2010年 10期
  • 【分类号】TP391.41
  • 【被引频次】20
  • 【下载频次】1933
  • 攻读期成果
节点文献中: 

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

本文的引文网络