在平衡速度与视觉效果的前提下,直接采用dynamicfollow-the-leader(DFTL)算法对头发进行快速的仿真.首先提出一种基于高斯核函数的快速插值算法,快速插值出平滑的发丝;然后采用偏移函数改变发束位置,产生卷发的效果;最后提出一种基于数学和物理的风力模型,通过调整风力因子控制风速大小实时地仿真头发受风力驱动的动态效果.动态仿真的实时渲染采用Kajiya-kay和Marschner2种光照模型,并使用deepopacitymaps算法产生头发自阴影.实验结果表明,文中提出的风力模型在头发仿真中得到了较好的动态效果,并具有良好的实时性.
This paper adopts the dynamic follow-the-leader method to achieve the balance between visual effect and speed in hair simulation. Firstly, we present a fast interpolation algorithm based on Gaussian kernel function,which can interpolate smooth hair fast. Then, the offset function is used to alter positions along the hair strand and create curliness on the hair. Finally, this paper proposes a wind model based on mathematics and physics, whichcan be used to simulate dynamic hair driven by wind in real time through controlling wind speed adjusted bywind factor. We render and shade the hair by two shading models, Kajiya-kay and Marschner, in real time, and deep opacity maps algorithm is also used to generate hair self-shadowing. The final experiments prove that our wind model performs well in the dynamic hair simulation, and has good real time results as well.