[cairo] [RFC] cairo_path_extents()

Carl Worth cworth at cworth.org
Mon Jan 21 15:25:28 PST 2008


On Mon, 21 Jan 2008 17:15:17 -0500, Behdad Esfahbod wrote:
> On Mon, 2008-01-21 at 16:52 -0500, Carl Worth wrote:
> > I might follow this up by instead making the new state just be the
> > conventional current_point and has_current_point. That should be much
> > easier to read and will actually drop the state necessary from two
> > Booleans to one.
>
> Yes, current_point is exactly what it is.

I tried that, noticed that all line_to points (except for the last one
in each sub-path) would get added twice, realized that's no real
performance concern, but then also realized that it could be avoided
by simply clearing has_current_point in the line_to callback, then
realized that would be a dishonest abuse of the conventional
"current_point" state, so I renamed it to move_to_point.

That is, I spent far too much time just to drop the word "trailing"
from this identifier.

Having heard no objection to the new semantics, (and thanks Behdad and
Brian for the feedback in IRC), I've now pushed the whole series out
to master.

So cairo_path_extents exists in master now. I think there's some
ancient Mozilla bug that will want to be closed soon...

-Carl
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.cairographics.org/archives/cairo/attachments/20080121/ebce83a0/attachment.pgp 


More information about the cairo mailing list