On Thu, Jul 29, 2010 at 10:09 AM, Oliver Hunt <span dir="ltr"><<a href="mailto:oliver@apple.com">oliver@apple.com</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<div><div></div><div class="h5">This is the way the webkit canvas implementation has always worked, firefox implemented this incorrectly, and the spec was based off of that implementation.<br></div></div></blockquote><div>
<br>I don't think "the spec was based off of that implementation" is true, since Firefox never matched the spec (certain operators such as "copy" were treated as source-bounded, because cairo does it that way, just like CG) until I fixed that relatively recently.<br>
<br></div><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><div><div class="h5"></div></div>
Additionally the webkit behaviour is more powerful than the spec behaviour as the spec behaviour can be emulated trivially on top of the webkit model, but vice versa is much harder and much more expensive.<br></blockquote>
<div> </div></div>They're both pretty easy to emulate in terms of the other. But I agree that emulating an unbounded operator in terms of the source-bounded operator has a higher performance penalty, since the easy implementation is to use a temporary surface, where as to emulate source-bounded using unbounded you just do some extra clipping.<br>
<br>As it happens, I'm expecting to see a proposal on public-canvas-api sometime soon that makes all composition source-bounded and has acceptable text defining the shape affected by the composition operation. It's tricky though, especially regarding shadows. But since I agree source-boundedness is more intuitive for authors, I'm open to changing Firefox to support it.<br>
<br clear="all">Rob<br>-- <br>"Now the Bereans were of more noble character than the 
Thessalonians, for they received the message with great eagerness and 
examined the Scriptures every day to see if what Paul said was true." [Acts 17:11]<br>