[cairo] new pattern interface patches and some great news about the OpenGL backend

David Reveman c99drn at cs.umu.se
Thu Apr 1 14:26:31 PST 2004

On Thu, 2004-04-01 at 14:20 -0500, Carl Worth wrote:
> Thanks for separating and versioning the patches. This helps a lot.
> I've started looking at:
>      http://www.cs.umu.se/~c99drn/cairo-pattern-040331.patch
> The attached patch cleans up a few minor issues, (a build break if the
> gl patch is not applied, a few missing prototypes, etc.). Oh, and
> you'll want to be careful to spell "default" correctly in your switch
> statements, (though I ended up using explicit enum values instead as
> that enables a useful compiler warning when new enum values are added
> but the switch statement is not updated).

ok, thanks for finding those issues.

> Take a look at my patch below and make sure that the "fall-through" I
> commented is intentional Please explicitly comment all such
> fall-throughs as otherwise they just look like bugs.

it's intentional. I'll remember to comment those in the future.

> And take a look at _cairo_image_surface_create_pattern to see if it
> shouldn't actually appear in some other module (cairo_pattern.c ?).

I think your right. I thought of this before but haven't got around to
change it.

> Additionally, the indentation on cairo_pattern.c should be made
> consistent with the other files.

yes, same thing with cairo_gl_surface.c. Can I use the indent program
with some nice options for this or should I do it by hand? 

> And what is the change to cairo_ft_font.c? A bug fix? It seems
> unrelated so please commit it separately from the rest.

It's needed for correct source offset in pattern surface. For linear and
radial patterns we only generate a pattern surface that is big enough to
cover the rendering area. Maybe I can get this source offset right in
some other way. I'll see what I can do.

- David

David Reveman <c99drn at cs.umu.se>

More information about the cairo mailing list