2010.08.08

Canvas Method Chaining

This week I’ve done some stuff using the HTML5 canvas and one feature that I kind missed was method chaining, so I decided to implement it…

It isn’t something ground-breaking - other people done it before (Canto.js, MDC canvas, p01, …) - but I decided to implement it by myself since it’s something simple, the other solutions are way more complex than what I needed, source code isn’t that clean and/or overwrites native objects prototypes (possibly causing conflicts/issues), etc…

I’ve released the code as open source under the WTFPL and it is available on GitHub.

Check the project page on GitHub for more details.

I hope it is useful for someone.

PS: I’m not a big fan of method chaining since code tends to be become “more cryptic” but sometimes it makes sense to use, use it with moderation!


2010.04.03

Converting SVG to FIVe3D, Flash Vector Graphics and HTML5 canvas

3d vector tiger

This post is being delayed forever since I was planning to improve my SVG parser but finally I decided to release it since I don’t have plans to work on it anymore.. the basic functionalities are working since July 2009 and I abandoned the project for a while just going back to it a couple months ago when I finally decided to fix a few bugs and add the option to export HTML5 Canvas and Flash AS3 drawing commands… so let’s explain how it all started.
Read more…