Rendering fonts on OpenGL

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Rendering fonts on OpenGL

Igor Stasenko
Hello,

This is a Tahoma font, rendered with OpenGL

look how much difference between no-AA
and with enabled multisampling.

I think that with multisampling, the quality is quite good to not
bother about sub-pixel AA.
Sub-pixel AA could be added later, if there's any brave soul who can
implement a fragment shader for it :)

Moreover, with multisampling, all fragments on screen (lines, points,
polygons) will also be automatically antialiased.
This means no rigid edges for everything, not just for fonts :)

--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

tahoma-noAA.png (17K) Download Attachment
tahoma-MSAA-8.png (28K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Rendering fonts on OpenGL

melkyades
Hi, may I ask how you are rendering these fonts? You parse the glyphs and then render lines with opengl or use freetype to render to a texture without antialiasing or both? If you asked me, I'd say I like the method but for fonts they look a bit blury, I'd say too much for the smaller ones. Also, what are you working on?

Regards,
            Javier.

2010/5/23 Igor Stasenko <[hidden email]>
Hello,

This is a Tahoma font, rendered with OpenGL

look how much difference between no-AA
and with enabled multisampling.

I think that with multisampling, the quality is quite good to not
bother about sub-pixel AA.
Sub-pixel AA could be added later, if there's any brave soul who can
implement a fragment shader for it :)

Moreover, with multisampling, all fragments on screen (lines, points,
polygons) will also be automatically antialiased.
This means no rigid edges for everything, not just for fonts :)

--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project



--
Javier Pimás
Ciudad de Buenos Aires

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Rendering fonts on OpenGL

Igor Stasenko
2010/5/23 Javier Pimás <[hidden email]>:
> Hi, may I ask how you are rendering these fonts? You parse the glyphs and
> then render lines with opengl or use freetype to render to a texture without
> antialiasing or both?

Squeak has already a TT font reader, so i just taking the data from there
and piping to GPU.
What you see here is freely scalable vector/curve rendering done
completely on GPU.

> If you asked me, I'd say I like the method but for
> fonts they look a bit blury, I'd say too much for the smaller ones.

I think this is best what you can achieve without hinting / subpixel AA.

> Also, what are you working on?
>
I once did a GLCanvas,
and now i want to reiterate and improve it using new callout mechanism
(NativeBoost),
and full coverage of OpenGL API, with all extensions available at your disposal.

> Regards,
>             Javier.
>
> 2010/5/23 Igor Stasenko <[hidden email]>


--
Best regards,
Igor Stasenko AKA sig.

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Rendering fonts on OpenGL

Stéphane Ducasse

On May 23, 2010, at 11:04 PM, Igor Stasenko wrote:

> 2010/5/23 Javier Pimás <[hidden email]>:
>> Hi, may I ask how you are rendering these fonts? You parse the glyphs and
>> then render lines with opengl or use freetype to render to a texture without
>> antialiasing or both?
>
> Squeak has already a TT font reader, so i just taking the data from there
> and piping to GPU.
> What you see here is freely scalable vector/curve rendering done
> completely on GPU.
>
>> If you asked me, I'd say I like the method but for
>> fonts they look a bit blury, I'd say too much for the smaller ones.
>
> I think this is best what you can achieve without hinting / subpixel AA.
>
>> Also, what are you working on?
>>
> I once did a GLCanvas,
> and now i want to reiterate and improve it using new callout mechanism
> (NativeBoost),
> and full coverage of OpenGL API, with all extensions available at your disposal.

Igor it would be good it we could have

NativeBoostRomeCanvas

if you see what I mean :)

>
>> Regards,
>>             Javier.
>>
>> 2010/5/23 Igor Stasenko <[hidden email]>
>
>
> --
> Best regards,
> Igor Stasenko AKA sig.
>
> _______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project