#

API Docs for: 1.6.0
Show: Inherited Protected Private Deprecated

# CanvasMaskManager Class

Defined in: `src/pixi/renderers/canvas/utils/CanvasMaskManager.js:6`
Module: PIXI

A set of functions used to handle masking

- Index
- Methods

## Item Index

### Methods

- popMask
- pushMask

## Methods

### `popMask`

(

- `context`

)

Defined in `src/pixi/renderers/canvas/utils/CanvasMaskManager.js:39`

Restores the current drawing context to the state it was before the mask was applied

#### Parameters:

- `context` Context2D

  the 2d drawing method of the canvas

### `pushMask`

(

- `maskData`
- `context`

)

Defined in `src/pixi/renderers/canvas/utils/CanvasMaskManager.js:16`

This method adds it to the current stack of masks

#### Parameters:

- `maskData` Object

  the maskData that will be pushed

- `context` Context2D

  the 2d drawing method of the canvas