編輯

共用方式為


SKImage.FromPixels Method

Definition

Overloads

FromPixels(SKImageInfo, IntPtr, Int32)

Creates a new image from an in-memory buffer.

FromPixels(SKPixmap, SKImageRasterReleaseDelegate, Object)

Creates a new image from an in-memory buffer.

FromPixels(SKImageInfo, SKData, Int32)

Creates a new image from an in-memory buffer.

FromPixels(SKImageInfo, IntPtr)

Creates a new image from an in-memory buffer.

FromPixels(SKPixmap, SKImageRasterReleaseDelegate)

Creates a new image from an in-memory buffer.

FromPixels(SKImageInfo, SKData)
FromPixels(SKPixmap)

Creates a new image from an in-memory buffer.

FromPixels(SKImageInfo, IntPtr, Int32)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKImageInfo info, IntPtr pixels, int rowBytes);

Parameters

info
SKImageInfo

The image information describing the encoding of the image in memory.

pixels
IntPtr

The pointer to the image in memory.

rowBytes
Int32

The specified the number of bytes used per row in the image.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to

FromPixels(SKPixmap, SKImageRasterReleaseDelegate, Object)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKPixmap pixmap, SkiaSharp.SKImageRasterReleaseDelegate releaseProc, object releaseContext);

Parameters

pixmap
SKPixmap

The pixmap that contains the image information and buffer location.

releaseProc
SKImageRasterReleaseDelegate

The delegate to invoke when the image is about to be destroyed.

releaseContext
Object

The user data to use when invoking the delegate.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to

FromPixels(SKImageInfo, SKData, Int32)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKImageInfo info, SkiaSharp.SKData data, int rowBytes);

Parameters

info
SKImageInfo

The image information describing the encoding of the image in memory.

data
SKData

The data object that contains the pixel data.

rowBytes
Int32

The specified the number of bytes used per row in the image.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to

FromPixels(SKImageInfo, IntPtr)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKImageInfo info, IntPtr pixels);

Parameters

info
SKImageInfo

The image information describing the encoding of the image in memory.

pixels
IntPtr

The pointer to the image in memory.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to

FromPixels(SKPixmap, SKImageRasterReleaseDelegate)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKPixmap pixmap, SkiaSharp.SKImageRasterReleaseDelegate releaseProc);

Parameters

pixmap
SKPixmap

The pixmap that contains the image information and buffer location.

releaseProc
SKImageRasterReleaseDelegate

The delegate to invoke when the image is about to be destroyed.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to

FromPixels(SKImageInfo, SKData)

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKImageInfo info, SkiaSharp.SKData data);

Parameters

data
SKData

Returns

Applies to

FromPixels(SKPixmap)

Creates a new image from an in-memory buffer.

public static SkiaSharp.SKImage FromPixels (SkiaSharp.SKPixmap pixmap);

Parameters

pixmap
SKPixmap

The pixmap that contains the image information and buffer location.

Returns

A new image wrapping the specified buffer, or null on error.

Applies to