[whatwg] addPath and CanvasPathMethods
dschulze at adobe.com
Thu Mar 20 11:52:09 PDT 2014
On Mar 20, 2014, at 7:44 PM, Justin Novosad <junov at google.com> wrote:
> This would apply the CTM to the incoming path, correct? I am a little bit concerned that this API could end up being used in ways that would cancel some of the performance benefits (internal caching opportunities) of Path2D objects.
Where is the difference to fill(Path2D), stroke(Path2D) and clip(Path2D)? The path will always need to be transformed to the CTM. Graphic libraries usually do this already for you. The addPath() proposal is not different to that.
> On Thu, Mar 20, 2014 at 1:49 PM, Dirk Schulze <dschulze at adobe.com> wrote:
> On Mar 20, 2014, at 6:31 PM, Rik Cabanier <cabanier at gmail.com> wrote:
> > addPath is currently defined on the Path2D object. 
> > Is there a reason why it's not defined on CanvasPathMethods instead? That
> > way this method is available on the 2d contest so you can append a path to
> > the current graphics state.
> > This would also negate the need for setCurrentPath.
> I am supportive for this idea! I agree that this would solve one of the reasons why I came up with currentPath for WebKit in the first place.
> > 1:
> > http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#dom-path-addpath
More information about the whatwg