Canvas and jQuery? Canvas and jQuery? jquery jquery

Canvas and jQuery?


You can use jQuery to select the canvas element, but you'd have to use its own methods. A decent start would be https://developer.mozilla.org/en-US/docs/Web/API/Canvas_API/Tutorial.


jQuery is a toolkit to interact and manipulate the DOM plus some extra neat ajax methods. Raphael and/or Protovis are toolkits for visualisation.

Processing.js is a visualisation toolkit specifically for the canvas element.

jQuery has one expertise, other toolkits have other expertise, though it's very much possible to use specialisation toolkits together ;)


The direct answer is no because jQuery is based on DOM querying and manipulation. Canvas elements are drawn using the Canvas API with JavaScript. If you're looking for a good canvas library, you might try out KineticJS. It adds animation and event support for canvas applications.