Hi Eric,
Thank you for your offer of adding additional stuff to the fontconfig
patch. I'm not sure how the details would work (or IF it would work),
but I think the best thing would be to add an arbitrary "filter" option
where a string name and a signed int (or float?) value can be passed to
fontconfig, and it will make a call to freetype using those. That way,
new filters and features (like brightness, contrast, gamma, sharpening,
etc.) could be added to Freetype without requiring a change to
fontconfig code (just fontconfig configuration files). This would also
require a change to Freetype, which I'd help with. Perhaps it would
still have to use explicitly given fontconfig parameters like "filter1",
"filter2", "filter3", up to 20 or so. The meaning of the values would
vary depending on the filter chosen.
Example:
<match target="font" >
<test name="family" qual="any" >
<string>Courier</string>
</test>
<edit mode="assign" name="filter1" >
<string>brightness</string>
</edit>
<edit mode="assign" name="filter1value" >
<int>-50</int>
</edit>
</match>
Comments anyone? Werner?
Thanks,
Erik
On 11/21/2011 01:14 AM, Eric Rannaud wrote:
Erik,
I notice that for Infinality you have other settings that users may
want to control via fontconfig. Some of Infinality settings may be
generic enough that other renderers could use them as well. Anything
other than lcdfiltercustom that I should add to my patch?
The point being that, for any change to fontconfig, corresponding
changes must be pushed to users of fontconfig (Cairo and Xft are
probably the principal users) for the new option to become usable. So
we might as well push as many improvements as possible at once.
I'm submitting the fontconfig patch that I posted here to the
fontconfig mailing list (with 5 double values). I will explain about
asymmetric filters, range of values and alternatives (such as 0 -
1000).
I will also propose having a "lcdheavy" value for lcdfilter, but I
don't really think it makes a lot of sense, as it's fairly arbitrary
what lcdheavy should mean. After all, infinality-settings.sh lists 8
perfectly reasonable set of filter values, and we're not going to have
a constant for each possible filter configuration.
I will also have patches for Cairo and Xft, to honor whatever
configuration option the fontconfig people accept, and pass it back to
freetype.
Thanks.
_______________________________________________
Freetype-devel mailing list
[email protected]
https://lists.nongnu.org/mailman/listinfo/freetype-devel