ColorMatrix.multiply constructor
ColorMatrix.multiply(
- UvColor color
Returns a multiply-style transform using color as the multiplier.
Implementation
factory ColorMatrix.multiply(UvColor color) {
final resolved = _resolveRgb(color);
if (resolved == null) return identity;
return ColorMatrix(<double>[
resolved.r / 255.0,
0,
0,
0,
0,
0,
resolved.g / 255.0,
0,
0,
0,
0,
0,
resolved.b / 255.0,
0,
0,
0,
0,
0,
1,
0,
]);
}