我有一个带有图像的画布元素。
现在我尝试在单击按钮时旋转画布中的图像:
$("#rotateC").live('click',function(e) {
e.preventDefault();
console.log("rotateC");
Pixastic.process(firstImg, 'rotate',
{
'angle': +90,
'leaveDOM': true
},
function(firstImg) {
ctx.drawImage(firstImg, 0, 0);
}
);
});
图像将旋转一次,然后如果我再次单击该按钮,则没有任何反应。
你知道问题是什么吗?