Page 1 of 1
Font Antialiasing?
Posted: Sun Jul 21, 2013 11:33 pm
by nobody
I was wondering if there's a possibility of the addition of font antialiasing (for the custom chat).
This can easily be done with Graphics2D, my friend and I even have a really nice font renderer of ourselves that we'd be more than willing to let you guys use.
Re: Font Antialiasing?
Posted: Mon Jul 22, 2013 12:41 am
by Swifty
Que?
Re: Font Antialiasing?
Posted: Mon Jul 22, 2013 12:14 pm
by Mr_Blobby
Por que?
Seems rather pointless.
Re: Font Antialiasing?
Posted: Tue Jul 23, 2013 8:32 pm
by nidefawl
I wrote that fontrenderer myself over 2 years ago. I found that implementations of the Graphics2D class are Operating System/Virtual Machine dependent.
I get very good fonts on Windows 7. The results were a lot worse on MacOS.
Overall the results were better with the Antialiasing hint disabled.
I think antialiasing would give better results if I rendered the single Characters to a bigger texture.
Right now a single character doesn't use enough pixels to allow any interpolation between them.
Can you send me a screenshot of a font that you would think needs better antialising?
Those are the current hints that get used right now:
Code: Select all
boolean useAA = false;
g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, useAA ? RenderingHints.VALUE_ANTIALIAS_ON : RenderingHints.VALUE_ANTIALIAS_OFF);
g.setRenderingHint(RenderingHints.KEY_TEXT_ANTIALIASING, useAA ? RenderingHints.VALUE_TEXT_ANTIALIAS_ON : RenderingHints.VALUE_TEXT_ANTIALIAS_OFF);
g.setRenderingHint(RenderingHints.KEY_FRACTIONALMETRICS, RenderingHints.VALUE_FRACTIONALMETRICS_OFF);
g.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_QUALITY);
g.setRenderingHint(RenderingHints.KEY_COLOR_RENDERING, RenderingHints.VALUE_COLOR_RENDER_QUALITY);
g.setRenderingHint(RenderingHints.KEY_ALPHA_INTERPOLATION, RenderingHints.VALUE_ALPHA_INTERPOLATION_QUALITY);
g.setRenderingHint(RenderingHints.KEY_STROKE_CONTROL, RenderingHints.VALUE_STROKE_NORMALIZE);