• 中国计算机学会会刊
  • 中国科技核心期刊
  • 中文核心期刊

J4 ›› 2014, Vol. 36 ›› Issue (11): 2196-2202.

• 论文 • 上一篇    下一篇

基于分段函数的中国画风格渲染新方法

陈晨,杜晓荣,陈启文   

  1. (中山大学电力电子及控制技术研究所,广东 珠海 519082)
  • 收稿日期:2013-04-09 修回日期:2013-07-05 出版日期:2014-11-25 发布日期:2014-11-25
  • 基金资助:

    广东省省部产学研重点项目(2008A090400013);珠海市科技计划资助项目(2012D0501990009)

A novel rendering method for Chinese painting
style based on piecewise function          

CHEN Chen,DU Xiaorong,CHEN Qiwen   

  1. (Institute of Power Electronic and Control Technology,Sun YatSen University,Zhuhai 519082,China)
  • Received:2013-04-09 Revised:2013-07-05 Online:2014-11-25 Published:2014-11-25

摘要:

通过结合物理模拟中随机浓度的思想和分段处理方法,对中远距离分段的扩散浓度采取随机处理,从而提出一种新的分段水墨扩散函数,用于模拟水墨扩散效果,根据其实现要点选取适当算法设计了中国画风格绘制的总体算法框图。该算法首先对图像用均值滤波进行平滑预处理;然后应用Kmeans聚类算法进行图像分割,用以模拟中国画用水墨浓淡表达色调层次的效果;接着,算法采用形态学方法检测图像的边缘点,对检测出来的边缘点应用自定义的分段处理函数模拟水墨边缘扩散的效果,得出中国画风格渲染图像;最后,用HTML5实现了该算法。该算法所生成的中国画风格在用墨模拟和水墨扩散上都能够得到较逼真的效果。

关键词: 非真实感绘制(NPR), 中国画, HTML5, 分段函数, Kmeans聚类算法

Abstract:

By combining the ideas of random concentration in physical simulation and the piecewise approach,the random process of diffusion density of the middle-long distance segment is performed,then a novel subparagraph ink spread function is proposed for simulating the ink diffusion effect.A novel rendering method of Chinese painting style based on piecewise function is proposed.According to the design key points,the overall framework of the proposed method is designed.Firstly,the mean filter is used for smoothing preprocessing of the image.Secondly,the Kmeans clustering algorithm is adopted for image segmentation so as to simulate the tonal gradation effect expressed by ink shades in Chinese painting.Thirdly,the morphological method is used to detect the edge points.Fourthly,the self-defined piecewise function is applied to the detected edge points to simulate the effect of the diffusion of ink edges,thus obtaining the rendered image of Chinese painting style.Finally,HTML5 is used to implement the proposal. The proposed algorithm can generate a more realistic effect for ink simulation and ink diffusion of Chinese painting style.     

Key words: non-photorealistic rendering;Chinese painting;HTML5;segmented function;K-means clustering algorithm