Does QImage::Format_Mono support text antialiasing?
-
Hi,
I want to generate a Format_Mono bitmap from QPainter drawing some text.
But the result looks really bad on antialiasing(with antialiasing option enabled).
when I tried use the ARGB32 format it looked very well.
So does Format_Mono support text antialiasing? Is there any workaround for it?Thanks.
-
Hi itomakoto,
QImage::Format_Mono is a 1 bit format and then antialiasing is impossible.
Only 2 level of color...
-
[quote author="Dagal" date="1373537803"]Hi itomakoto, QImage::Format_Mono is a 1 bit format and then antialiasing is impossible. Only 2 level of color... [/quote]
Hi Dagal, thank you for the reply.
I am so curious that actually the 1bit-map isn't 'not antialiased', it is generated with some noise pixel.
For example, if I draw the character 'I', so ideally the pixel map should be likeoo
oo
oo
oo
oo
, suppose 'o' means a pixel.But what I got from qt is like
oo
oo
ooo <-- one noise pixel
oo
ooo <---another one noise pixel
ooARGB32 doesn't have this issue.
-
antialiasing create always "noise pixels" lighter or darker color and then, you see soft lines.
If you have a 1 bit image, you can have white and black pixels (no gray available)
ARGB32 have the same issue but you don't see it... (16M Colors)