# class CanvasPattern

#### package js.html

Available on HTML5

The `CanvasPattern` interface represents an opaque object describing a pattern, based on an image, a canvas or a video, created by the `CanvasRenderingContext2D.createPattern()` method.

Documentation CanvasPattern by Mozilla Contributors, licensed under CC-BY-SA 2.5.

See:

https://developer.mozilla.org/en-US/docs/Web/API/CanvasPattern

### Methods

###

`setTransform (matrix:Matrix):Void`

Applies an `SVGMatrix` representing a linear transform to the pattern.