setTransform method

void setTransform([
  1. JSAny aOrTransform,
  2. num b,
  3. num c,
  4. num d,
  5. num e,
  6. num f,
])

The CanvasRenderingContext2D.setTransform() method of the Canvas 2D API resets (overrides) the current transformation to the identity matrix, and then invokes a transformation described by the arguments of this method. This lets you scale, rotate, translate (move), and skew the context.

Note: See also the CanvasRenderingContext2D.transform method; instead of overriding the current transform matrix, it multiplies it with a given one.

Implementation

external void setTransform([
  JSAny aOrTransform,
  num b,
  num c,
  num d,
  num e,
  num f,
]);