当在GDI +中以一定角度绘制字符串时,AntiAlias失败

时间:2009-12-24 09:38:17

标签: c++ string gdi+ antialiasing

我使用以下代码绘制字符串。在GDI +

Graphics tempFontGr(XXX);
Matrix* myPathMatrix = NULL;
 myPathMatrix->Rotate(GetDCAngle(), MatrixOrderPrepend);
cantempFontGr.SetTransform(myPathMatrix);
tempFontGr.SetInterpolationMode(InterpolationModeHighQuality);
tempFontGr.SetSmoothingMode(SmoothingModeAntiAlias);
tempFontGr.DrawString(m_sWords, -1, tempFont.get(), tempRec, NULL, m_pBrush.get());

绘制的字符串有别名是很烦人的。有没有删除别名的方法? 非常感谢!

1 个答案:

答案 0 :(得分:1)

SetSmoothingMode适用于直线和曲线。试试SetTextRenderingHint