color_matrix() method allows you to recalculate color values by applying a matrix transform. A matrix can be up to a 6×6 grid where each column maps to a color channel to reference, and each row represents a color channel to effect.red, green, blue, n/a, alpha, and a constant (a.k.a offset) describe the corresponding rows and columns.
Parameter Input Type Description matrix collections.abc.Sequence 2d list of doubles.
Source Image :
Attention geek! Strengthen your foundations with the Python Programming Foundation Course and learn the basics.
To begin with, your interview preparations Enhance your Data Structures concepts with the Python DS Course.