Knovajs / HTML5 Canvas - Rotation origin
问题 I have successfully created a button which rotates an image either clockwise or C-Clockwise. However, this button can only be used once. i.e. if i press CW i cannot then use CCW to revert the image back. Any ideas? $rw = $('#rotate_right'); $rw.on('click', function(event) { event.preventDefault ? event.preventDefault() : event.returnValue = false; darthVaderImg.offsetX(img_width / 2); darthVaderImg.offsetY(img_height / 2); // when we are setting {x,y} properties we are setting position of top