HTML5 Canvas Grayscale Image Filter Tutorial
To apply filter to an Konva.Image
, we have to cache it first with cache()
function. Then apply filter with filters()
function.
To invert the colors of an image with Konva, we can use the
Konva.Filters.Grayscale
filter.
For all available filters go to Filters Documentation.
- Vanilla
- React
- Vue