[cairo] Pixman sampling coordinates

Carl Worth cworth at cworth.org
Tue Jan 22 16:12:33 PST 2008


On Tue, 22 Jan 2008 10:42:30 +0100, Bertram Felgenhauer wrote:
> I can write up the math if there's any interest. (It's simple, but
> slightly messy.)

Enlightening comments in the code are always appreciated. So please
feel free to do so if you're interested, (but it won't block the
patches either way).

> Hmm, git am produces too many mails for my taste, with small patches
> like these. I guess I could use git-format-patch and attach all the
> files, but attachments in mailbox format also seem a bit silly.

I agree. The original git author and community use a
one-patch-per-email style where I'm much happier with a nice clean
series of patches contained in a single mail like you did. And it does
feel rather silly to attach things in mailbox format in that case. One
thing I have done is to use something like:

	git format-patch --stdout origin/master > patch-series.mbox

where you'll still end up attaching a silly mailbox-formatted file,
but it's at least a lot more convenient since there's only one.

> I have now.
>     git-pull git://people.freedesktop.org/~inte/pixman sampling

Thanks! So for me that's a nice:

	git remote add inte git://people.freedesktop.org/~inte/pixman
	git fetch inte

And then I can examine the branch with things like:

	git log -p origin/master..inte/sampling

And I'll just be a "git fetch inte" from exploring any future work you
do.

If anyone isn't using "git remote" like that yet, just learn those
steps above. It's wonderfully convenient for tracking several other
people's personal repositories.

> Ok, I redid that patch. And you were right, there was a assignment
> missing there, thanks.

Thanks.

I think I'll still tweak it from:

	#if N_BITS == 1
		lx = l->x + X_FRAC_FIRST(1);
		rx = r->x + X_FRAC_FIRST(1);
	#else
		lx = l->x;
		rx = r->x
	#endif

to:

		lx = l->x;
		rx = r->x;
	#if N_BITS == 1
		lx += X_FRAC_FIRST(1);
		rx += X_FRAC_FIRST(1);
	#endif

just to reduce the amount of #ifdefing. But I am quite glad to see
that you added a comment there explaining why this adjustment isn't
necessary for the case of other values of N_BITS.

I'll just do that in a separate commit after pushing this series.

Once again, thanks for doing this work! I hope it was fun for you.

-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/20080122/dcd893d5/attachment.pgp 


More information about the cairo mailing list