Table of Contents

Method CreateSkiaSurface

Namespace
Alternet.Drawing
Assembly
Alternet.UI.Common.dll

CreateSkiaSurface(Image, ImageLockMode)

Creates ISkiaSurface object for the specified image. Consider using transparent images as they are handled faster. Solid images are handled slower as they are converted to GenericImage before rendering. This is required as SkiaSharp does not support all pixel formats. Also on MacOS all images are handled via GenericImage as native image pixels cannot be accessed directly via SkiaSharp.

public static ISkiaSurface CreateSkiaSurface(Image image, ImageLockMode lockMode)

Parameters

image Image

Image on which ISkiaSurface object is created.

lockMode ImageLockMode

Image lock mode.

Returns

ISkiaSurface

CreateSkiaSurface(GenericImage, ImageLockMode)

Creates ISkiaSurface object for the specified generic image.

public static ISkiaSurface CreateSkiaSurface(GenericImage image, ImageLockMode lockMode)

Parameters

image GenericImage

Image on which ISkiaSurface object is created.

lockMode ImageLockMode

Image lock mode.

Returns

ISkiaSurface