摘要
为了提高水面波动效果模拟的实时性并保持真实感,提出一种基于可编程图形处理器(GPU)的向量代数运算模型,并使用该模型求解水波动方程以加速水波仿真过程。给出了模型的数据结构定义和数据操作设计,对二维水波微分方程进行离散化处理,将其表达为矩阵矢量相乘的形式,再采取共轭梯度法进行求解,以获得代表水面的高度图。通过高度图信息来生成法线,从而获得水面反射和折射效果。实验结果表明,该算法充分发挥了GPU的高速性能优势来求解复杂的水面波动方程,能有效提高真实感水波纹模拟的效率。
A novel GPU based vector computation model is proposed to improve the simulation of water ripple,which is physically described by the wave equation.Firstly,the data structure and data operation rule are established to meet the needs of vector computation model.Secondly,the wave equation governing the water ripple is transformed discretely into vector multiplication,which would be solved by conjugate gradient method.Finally,the water ripple rendering is achieved from the height map providing the normal information used by the computation of light reflection and refraction.Experimental results show that the algorithm is efficient to simulate real-time water ripple by making full use of the powerful computation ability of GPU.
出处
《计算机工程与设计》
CSCD
北大核心
2010年第15期3514-3517,共4页
Computer Engineering and Design
基金
教育部科技研究重点基金项目(JK2G02035)
广电总局科技基金项目(2007-07)