Text Time Number without antialiasing?


Hey Guys,
How make text time number without antialiasing?
Not

Just increase the resolution with obj.resolution = 10

10 is a bit much.

just try what the lowest number is that works (can be float - can be 1.5 or 1.2781247128914 or smt)

i just create an overlay ortho camera with a size of 64, then size the text accordingly. i find it might even look better then just increasing the resolution. plus it saves a line of code.

Where do I increase the resolution? This in Python? :spin:

Yes its in python.

yep.If you don’t know python, I’ve made a simple script to solve your problem. Run this script 1 time in your text objects (you can play with the number “2” to increase or decrease the resolution. Just remember to keep this number low):

from bge import logic as g
o = g.getCurrentController().owner

o.resolution = 2

PS: Just correcting your question: “without antialiasing” means that you want to keep the alias to your text. Did you probabily mean: “without aliasing” or even “with antialiasing”. :smiley:

Why would you import logic as g? That is such an ugly and antiquated way of importing logic in the bge. By simply importing logic without renaming it, it is more understandable when looking through code than just having a single character be a variable.

Yesterday, for completely other reasons, I went and dug through the KX_FontObject source to find out what the resolution is actually doing.

What is a resolution of 1? Is is “100 pixels height per blender unit height”
So if your font object is 0.2 unit high, then a resolution of one is 100*0.2 = 20 pixels per character. This sizing is taken both from object scale and from the settings in the font panel

Very Very cool guys
Sure here!!
Thanks

Cuz I like it :smiley:

Wow, good explanaltion! Thnaks for sharing it!