Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

rotate method

Rotates the current context coordinates (that is, a transformation matrix).

HTML Canvas 2D Context, Section 3Internet Explorer 9

Syntax


object.rotate(angle);

Parameters

angle [in]

Type: number

The rotation angle, in radians.

Return value

This method does not return a value.

Standards information

Remarks

Rotation is based on the current origin.

When you rotate an image, wait until the image is fully loaded before calculating any rotation. This is because the width and height aren't available until the image has loaded and will result in incorrect calculations.

See also

ICanvasRenderingContext2D::translate

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.