Exemple #1
0
        private void GetSKPaintFill(ArgbColor color, bool isAntialias, out SKPaint brush)
        {
            if (color.IsDirty == true || !_paintCache.TryGetValue(color, out var brushCached))
            {
                color.Invalidate();
                brushCached        = SkiaHelper.ToSKPaintBrush(color, isAntialias);
                _paintCache[color] = brushCached;
            }
            else
            {
                SkiaHelper.ToSKPaintBrushUpdate(brushCached, color);
            }

            brush = brushCached;
        }