gpt4 book ai didi

c++ - 在 GDI+ 中以特定角度绘制字符串时 AntiAlias 失败

转载 作者:行者123 更新时间:2023-11-28 08:31:14 24 4
gpt4 key购买 nike

我正在使用以下代码绘制字符串。在 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());

令人讨厌的是绘制​​的字符串有别名。有什么方法可以删除别名吗?非常感谢!

最佳答案

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

关于c++ - 在 GDI+ 中以特定角度绘制字符串时 AntiAlias 失败,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/1957581/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com