How can I draw a droppable image into a canvas.
I know I should use :
var c=document.getElementById("myCanvas");
var ctx=c.getContext("2d");
var img=document.getElementById("image");
ctx.drawImage(img,//drop x position ,//drop y position);
Can I achieve this using jquery
Updated demo with position correction: http://jsfiddle.net/techfoobar/VFZ4m/2/
Yes, you can do this. Check this demo: http://jsfiddle.net/techfoobar/VFZ4m/1/
Note that you’ll need to fine tune the x, y where image is drawn on the canvas.
HTML:
JS: