开发者

javascript canvas rescaling and drawing on image

How can I use Canvas to draw over images downloaded by users, while scaling it?

Example:

  1. user uploaded image
  2. began to draw on it
  3. zoom out and continued to draw more

All changes ar开发者_开发知识库e applied to the original image.


One issue you will run into is IE. IE does not support canvas but you can use a library like ex-canvas to do the same in VML.

Canvas does allow to import images. When you do draw image you can set the size. I'm not sure if this is supported in VML\IE though.

ctx.drawImage(img,j*50,i*38,50,38); 
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜