为了将真实图像转换为油画风格,提出一种油画风格化绘制的算法.首先根据油画绘制特点,结合改进的双边滤波与数学形态学操作来建立金字塔结构的多层参考图像序列;然后提出基于视觉重要性图的笔画布置算法.通过使用人脸、视觉焦点检测等方法来检测重要性区域,并根据这些区域信息进行画笔绘制的起点、方向计算精度改进和对图像纹理边界做加强约束,达到了油画内容主次分明的效果.实验结果表明,采用文中算法能够达到较好的视觉效果.
To achieve painterly stylization for a real image, a new painterly rendering algorithm is proposed in this paper. Firstly according to the characteristics of painterly rendering, we combine an improved bilateral filter with the mathematical morphological operation to construct a pyramid sequence of multi-scale reference images. Then a stroke computing algorithm based on visual saliency is introduced. In this method, face and visual focus detections are first employed to get the salient regions. Based on the obtained salience information, the accuracy of stroke's control point and direction computing is improved, and the painting constraint to texture edge is strengthened. By using the proposed approach, a distinctive effect of painterly rendering that the primary content of the image is finely rendered can be achieved. Experimental results demonstrate that the improved painterly rendering algorithm produces satisfactory visual effects.