On 4/18/2016 10:03 AM, Maciej Sumiński wrote:
> On 04/15/2016 03:41 PM, "Torsten Hüter" wrote:
>> Hi Orson,
>> thanks for your nice work. I remember that we have discussed about this 
>> subject 
>> a few years ago - in general I think it's an advantage to
>> have an alternative for the stroke font. Not for performance, but for the 
>> visual 
>> quality.
>> I'd call it rather "outline font" instead of bitmap font, because that's 
>> more 
>> general - see also
>> https://en.wikipedia.org/wiki/Computer_font#OUTLINE
>> Of course you're using a texture for the font atlas, but the origin was a 
>> outline (or vector-) font.
>> For a higher quality at small sizes you need also a font atlas with 
>> different 
>> detail levels. I did some research back then and
>> found freetype-gl the best libary for these purposes.
>> https://github.com/rougier/freetype-gl
>> Perhaps you can reuse some code from them, for instance the atlas creation 
>> or 
>> the shaders.
> 
> Hi Torsten,
> 
> I had a look at the mentioned library when I was considering possible
> ways to go about the problem. It would be great if we wanted to use a
> number of fonts, especially to give possibility to use anything
> available in current system fonts, but in our case I do not see any
> advantage over the current method. If we were developing GIMP, then I
> surely would vote for it, but I think it is enough to have one font in
> KiCad.

Please don't dismiss this idea too quickly.  We've already discussed
using freetype to allow us to use any font even in boards.  We also
already have an indirect dependency on freetype via cairo so we wouldn't
be adding much in that regard.  Until we decide to support plotting arcs
in gerber files, this probably doesn't mean much but it's still
something to keep in mind.  I looked at freetype a while back and it
appears to do a good job of providing stroke outlines for all of the
font types it supports.  This may be a less problematic solution than
having to create our own stroke fonts and rendering them.  I don't want
to repoen the font discussion but if there is a good library that solves
our problem, I'm always willing to consider it rather than spending time
designing our own solution.

> 
> Likely it also means we ought to start shipping fonts with KiCad to be
> sure that texts can be rendered properly.

This is the age old problem.  Licensing issues with fonts will most
likely prevent you from shipping or embedding certain fonts so this
issue will always be present.  This problem still exists for all office
applications even if most users don't realize it.

> 
> It is not hard to rescale font atlas to get a few different sizes,
> either manually or with OpenGL mipmapping. If we really need to limit
> ourselves to a few possible font sizes then it can be done, but for the
> moment I do not see a big gain here.
> 
> Regards,
> Orson
> 
>> Thanks,
>> Torsten
>> I have just enabled regular OpenGL mipmapping, but I do not see a
>> significant difference. I consider the mentioned text (net name on pad
>> 1, C2) to be just too small to make it readable. If you compare the
>> original font and legacy view, they have the same problem and I am not
>> sure we can do much about it.
>>
>> Regards,
>> Orson
>>
>>
>>
>> _______________________________________________
>> Mailing list: https://launchpad.net/~kicad-developers
>> Post to     : kicad-developers@lists.launchpad.net
>> Unsubscribe : https://launchpad.net/~kicad-developers
>> More help   : https://help.launchpad.net/ListHelp
>>
> 
> 
> 
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~kicad-developers
> Post to     : kicad-developers@lists.launchpad.net
> Unsubscribe : https://launchpad.net/~kicad-developers
> More help   : https://help.launchpad.net/ListHelp
> 

_______________________________________________
Mailing list: https://launchpad.net/~kicad-developers
Post to     : kicad-developers@lists.launchpad.net
Unsubscribe : https://launchpad.net/~kicad-developers
More help   : https://help.launchpad.net/ListHelp

Reply via email to