I didn’t find any “how to disable label’s anti aliasing”, but there are a few tricks.
You can increase the font size and decrease the scale of the font. The following 2 links explains how to do it.
TL;DR this is the code snippet
// we multiply the font size by 2.0f
// and we divide the scale by 2.0f
auto yourLabel = Label::createWithTTF("example text", "fonts/arial.ttf", 36 * 2.0f);
yourLabel->setScale(1 / 2.0f); // you can modify the 1 to increase or decrease the scale of the font, (it doesn't affect the font size though)
this->addChild(yourLabel, 0); // addChild
But a post says that increasing the font size may take a lot of memory and eventually crash the device. I don’t know if this will happen to you, but if I increase the font size over ~48, my app crashes. Here is the topic I posted earlier.
Also, if you are using TTF, you can use BMFont. I’m not sure if it will help with the label though.
The label in my app is also blurry, so please reply when you find a solution for this.
Oh my, sorry. My response was too late.
Thanks for sharing a good way.
I just tested it and it’s definitely sharper than without this method, but the borders are still blurry.
I don’t know if it’s just my font, but when the font size is a multiple of 32, I get a completely clear label.
If you find another good way, I’ll share it. Thank you!!