提供如下的代码结构渲染字体

agg::conv_transform<...> conv (path,matrix);

agg::conv_curve<...> curve (conv);

agg::conv_contour<...> contour(curve);

 

curve.approximaltion_scale (scale);

contour.auto_detect_orientation (true);

contour.width (bold);

当bold大于零,表示放大,当bold小于零,表示缩小

采用conv_contour的理由

为了放大或者缩小字体

采用auto_detect_orientation的理由

从上面的所有关于该函数的说明都知道conv_contour扩展轮廓线实际上是会根据图形绘制的方向而有所不同,逆时针绘制的图形和顺时针绘制的图形,扩展轮廓线刚好相反,所以需要调用auto_detect_orientation设置为true,屏蔽顺时针和逆时针之间的区别。有些英文字母绘制是顺时针的比如a,逆时针比如c,详细可参考上传的图片,windows自带的图片查看器可打开!!