Hacker News new | ask | show | jobs
by aberatiu 4037 days ago
Really nice result, but there's one thing about it that really bugs me. http://imgur.com/KYQDTYD (Chrome on a Windows machine, if that's of any help).
2 comments

I believe this is caused by .clip() being "wonky" in Chrome. I think the better alternative to .clip() is:

  context.closePath();
  context.fill();
  context.globalCompositeOperation = "source-atop";
In action: http://codepen.io/anon/pen/mJOOxv

[1] http://www.w3.org/TR/2015/WD-2dcontext-20150514/#dom-context... [2] https://developer.mozilla.org/samples/canvas-tutorial/6_1_ca...

Looks like that in Firefox on Linux too.