节点文献
基于GPU的COONS曲面加速算法研究
Study on Acceleration Algorithm of COONS Surface Using GPU
【作者】 张勇;
【导师】 耿楠;
【作者基本信息】 西北农林科技大学 , 计算机应用技术, 2010, 硕士
【摘要】 Coons曲面作为三维建模中重要的基本单元,可以和NURBS和Bézier曲面相互结合起来完成图形的构建,因此,在建模造型应用中,常常先利用控制方便的Coons曲面等进行初步造型,作为后续NURBS曲面或Bézier曲面造型设计的基础。随着可编程图形处理单元(GPU)性能的不断增强,计算机图形的处理速度也得到了大幅度的提高,带动了与计算机图形相关应用领域的快速发展,这使得基于GPU的通用计算成为近几年来人们关注的一个研究热点。在本文的Coons曲面加速计算研究中,为了达到加速的目的,对传统双线性Coons曲面和分形Coons曲面进行了有针对性的设计,以便能更好的适应GPU通用计算的要求,从而并行构造出Coons曲面。本文的主要研究工作和结论如下:(1)基于GPU的加速功能,根据GPU输入数据的要求,构建并分解双线性Coons曲面。(2)基于GPU的加速功能,根据GPU输入数据的要求,构建分形Coons曲面。(3)基于GPU的通用计算框架,选用Microsoft VC++6.0、Intel OpenGL和Cg语言等开发工具,设计算法,实现上述曲面的GPU计算。(4)通过实验得出结论:随着插值点数的增加,片元程序执行时间的稳定性高于CPU程序,GPU并行计算的效率高于CPU;在基于GPU的运算过程中,较多较大块的数据在GPU和CPU之间传输,会影响GPU的效率;GPU片元程序在单图形管道的单循环中的运行时间小于多图形管道的多循环的运行时间。
【Abstract】 As one of the most important patterns for the three dimensional reconstruction, Coons surface can be employed to create graphics in combination with the NURBS and Bézier surfaces. In the area of surface modeling, usually Coons surfaces are used to generate preliminary models, based on which the NURBS or Bézier surfaces are then constructed.With the rapid enhancement on power of the Graphics Processing Unit (GPU), the computational speed of computer graphics raised greatly, which boosted the development of relevant applications. Consequently, general purpose computation on GPU has been a focus in recent yeas.In order to meet the requirement of general purpose GPU computation, we transformed the equations of traditional Coons surfaces. The transformed equations are decomposable and can be used for the parallel construction of Coons surface.The main work of this thesis is as follows:(1) Based on the computational power of GPU, we establish and decompose the bilinear Coons surface according to the input-data requirements of GPU.(2) Based on the computational power of GPU, we establish and decompose the fractal Coons surface according to the input-data requirements of GPU.(3) Based on the general GPU computing framework, algorithms are proposed to achieve the calculation of Coons surfaces on GPU. Our algorithms are implemented using the Cg language under a combined environment of Microsoft VC++ 6.0 and the Open GL library.(4) Through experiment we draw the conclusion that with the interpolation points increasing, execution time of fragment program still maintains stable to certain degree, without significant rise; the efficiency of GPU parallel computing is higher than CPU; In the process of operation based on GPU, there is much bulk data exchange between GPU and CPU, which will affect the efficiency of GPU; The time which a fragment program of GPU run in single-circulation of single-graph-pipeline is less than that in multi-circulation of multi-graph-pipeline.
【Key words】 Coons patches; GPU; vertex processor; fragment program;