[cairo] Wrong extents when rendering glyphs to non-integer positions

Uli Schlachter psychon at znc.in
Thu Oct 21 12:30:53 PDT 2010


Am 21.10.2010 20:57, Behdad Esfahbod wrote:
> On 10/21/10 08:26, Uli Schlachter wrote:
>> Hi,
>>
>> attached is a diff between current master and my try at this. I got this split
>> up into multiple commits at [1]. I hope this works roughly like you wanted it to
>> work.
> 
> Close.  Instead of a bool, use an enum with default/on/off like all the other
> font options.  Also, please turn it on for any backend that rounds.

I was hoping you would want me to use some better name than
"round_glyph_positions". Meh... :-)

Ok, done. New patch attached and uploaded (The old version is still available
under "-old"). I checked which backends round by grepping for _cairo_lround.
Since I don't have all the required stuff, I didn't compile-test with all
backends. However, the backend-specific change is always the same, so I hope
nothing broke here.

I know that this causes a new test suite failure for Xlib, although I haven't
investigated yet why. No idea about other backends.
Also, CAIRO_ROUND_GLYPH_POS_OFF isn't currently used anywhere.

So, how bad is this one now? :)

Cheers,
Uli

>> I only enable this for the image and xcb backends, because this is where I know
>> that it fixes test suite failures. Other backends could do the same if needed.
>>
>> Cheers,
>> Uli
>>
>> [1]
>> http://git.znc.in/?p=psychon/cairo.git;a=shortlog;h=refs/heads/glyph_pos_rounding



-- 
- Buck, when, exactly, did you lose your mind?
- Three months ago. I woke up one morning married to a pineapple.
  An ugly pineapple... But I loved her
-------------- next part --------------
A non-text attachment was scrubbed...
Name: round_glyph_positions.patch
Type: text/x-diff
Size: 9287 bytes
Desc: not available
URL: <http://lists.cairographics.org/archives/cairo/attachments/20101021/aff9aa10/attachment.patch>


More information about the cairo mailing list