discuss-gnustep
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

strokeadjust:ing by default


From: Alexander Malmberg
Subject: strokeadjust:ing by default
Date: Tue, 18 Jan 2005 14:59:55 +0100
User-agent: Mozilla Thunderbird 0.9 (X11/20041124)

Recently, I reworked back-art's handling of strokeadjust. In postscript. strokeadjusting will move points of paths around a bit to try to line things up with device pixels and make line widths seem more uniform. In back-art, I do things that are similar in spirit: adjust points on paths, line widths, and dash offsets to make the results sharper and clearer. The drawback of this is that by moving things around, you distort the paths a bit.

As an example, here a are a bunch of lines without strokeadjusting:

http://web.telia.com/~u42308495/alex/backart/lines_strokeadjust_off.png

and with:

http://web.telia.com/~u42308495/alex/backart/lines_strokeadjust_on.png

Note that with strokeadjusting, the results are much sharper. However, the results without strokeadjusting are more accurate: the lines really are placed "between" pixels.

back-art used to apply some simple adjusting always, but I've now changed it so that it's only applied when strokeadjusting is on, and, after thinking about it a bit, it seems best to me to enable it by default. All of the normal views benefit from clear rendering on screen, so it seems better to have the exceptions turn strokeadjusting off than to make everyone else have to turn it on all the time.

Thus, unless there are any serious objections, I'll commit that shortly. In cases where you really need accurate rendering, remember to call PSsetstrokeadjust(0) before drawing (e.g. in -setUpGState).

- Alexander Malmberg




reply via email to

[Prev in Thread] Current Thread [Next in Thread]