Canvas Rotation Principle
Bild rotation uses HTML5 Canvas API's rotate() method für coordinate system transfürmation. The algorithm Erste moves the canvas origin to the Bild center, applies rotation transfürmation, then draws the rotated Bild. für 90° multiples, simple coordinate swapping optimizes perfürmance; für arbitrary angles, trigonometric calculations are Erforderlich to determine new coordinates.