private SKShader ToShader(bool isOpaque, SKData uniforms, SKShader[] children, SKMatrix *localMatrix)
        {
            var uniformsHandle = uniforms?.Handle ?? IntPtr.Zero;

            using var childrenHandles = Utils.RentHandlesArray(children, true);

            fixed(IntPtr *ch = childrenHandles)
            {
                return(SKShader.GetObject(SkiaApi.sk_runtimeeffect_make_shader(Handle, uniformsHandle, ch, (IntPtr)childrenHandles.Length, localMatrix, isOpaque)));
            }
        }
Exemple #2
0
 public SKShader ToShader(SKShaderTileMode tmx, SKShaderTileMode tmy, SKMatrix localMatrix) =>
 SKShader.GetObject(SkiaApi.sk_bitmap_make_shader(Handle, tmx, tmy, &localMatrix));
Exemple #3
0
 public SKShader ToShader(SKShaderTileMode tmx, SKShaderTileMode tmy) =>
 SKShader.GetObject(SkiaApi.sk_bitmap_make_shader(Handle, tmx, tmy, null));
Exemple #4
0
 public SKShader ToShader(SKShaderTileMode tileX, SKShaderTileMode tileY, SKMatrix localMatrix) =>
 SKShader.GetObject(SkiaApi.sk_image_make_shader(Handle, tileX, tileY, &localMatrix));
Exemple #5
0
 public SKShader ToShader(SKShaderTileMode tileX, SKShaderTileMode tileY) =>
 SKShader.GetObject(SkiaApi.sk_image_make_shader(Handle, tileX, tileY, null));
Exemple #6
0
 public SKShader ToShader(SKShaderTileMode tmx, SKShaderTileMode tmy, SKMatrix localMatrix, SKRect tile) =>
 SKShader.GetObject(SkiaApi.sk_picture_make_shader(Handle, tmx, tmy, &localMatrix, &tile));