Skia.Controls.Avalonia is useful even outside the SVG packages. It gives you a set of reusable controls for drawing Skia content directly.
SKCanvasControlSKBitmapControlSKPathControlSKPictureControlSKPictureImageSKCanvasControlHook the draw event and render with raw SkiaSharp:
CanvasControl.Draw += (_, e) =>
{
e.Canvas.DrawRect(SKRect.Create(0f, 0f, 100f, 100f), new SKPaint { Color = SKColors.Aqua });
};
SKPictureControlThis control is a natural companion to Svg.Skia because SKSvg.Picture can be assigned directly:
<local:SKPictureControl Picture="{x:Static local:Tiger.Picture}" Stretch="Uniform" />
SKPictureImageUse SKPictureImage when a normal Avalonia Image should render an SKPicture:
<Image>
<Image.Source>
<local:SKPictureImage Source="{x:Static local:Camera.Picture}" />
</Image.Source>
</Image>
This is useful when:
SKPicture,