SKPixmap.Encode Method

Definition

Overloads

Encode(SKWStream, SKBitmap, SKEncodedImageFormat, Int32)

Encodes the bitmap using the specified format.

Encode(SKWStream, SKPixmap, SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

Encode(SKWStream, SKPixmap, SKPngEncoderOptions)

Encodes the pixmap as a PNG.

Encode(SKWStream, SKPixmap, SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

Encode(SKWStream, SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

Encode(SKWStream, SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

Encode(SKPngEncoderOptions)

Encodes the pixmap as a PNG.

Encode(SKWStream, SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

Encode(SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

Encode(SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

Encode(SKWStream, SKPixmap, SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

Encode(SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

Encode(SKWStream, SKPngEncoderOptions)

Encodes the pixmap as a PNG.

Encode(SKWStream, SKBitmap, SKEncodedImageFormat, Int32)

Encodes the bitmap using the specified format.

public static bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKBitmap src, SkiaSharp.SKEncodedImageFormat format, int quality);

Parameters

dst
SKWStream

The stream to write the encoded bitmap to.

src
SKBitmap

The bitmap to encode.

format
SKEncodedImageFormat

The file format used to encode the bitmap.

quality
Int32

The quality level to use for the bitmap.

Returns

Returns true on success, or false if there was an error.

Encode(SKWStream, SKPixmap, SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

public static bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKPixmap src, SkiaSharp.SKWebpEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

src
SKPixmap

The pixmap to encode.

options
SKWebpEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Encode(SKWStream, SKPixmap, SKPngEncoderOptions)

Encodes the pixmap as a PNG.

public static bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKPixmap src, SkiaSharp.SKPngEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

src
SKPixmap

The pixmap to encode.

options
SKPngEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Encode(SKWStream, SKPixmap, SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

public static bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKPixmap src, SkiaSharp.SKJpegEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

src
SKPixmap

The pixmap to encode.

options
SKJpegEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Encode(SKWStream, SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

public bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKEncodedImageFormat encoder, int quality);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

encoder
SKEncodedImageFormat

The file format used to encode the pixmap.

quality
Int32

The quality level to use for the pixmap.

Returns

Returns true on success, or false if there was an error.

Encode(SKWStream, SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

public bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKWebpEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

options
SKWebpEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Encode(SKPngEncoderOptions)

Encodes the pixmap as a PNG.

public SkiaSharp.SKData Encode (SkiaSharp.SKPngEncoderOptions options);

Parameters

options
SKPngEncoderOptions

The options to use when creating the encoder.

Returns

Returns the SKData wrapping the encoded pixmap.

Encode(SKWStream, SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

public bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKJpegEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

options
SKJpegEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Encode(SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

public SkiaSharp.SKData Encode (SkiaSharp.SKEncodedImageFormat encoder, int quality);

Parameters

encoder
SKEncodedImageFormat

The file format used to encode the pixmap.

quality
Int32

The quality level to use for the pixmap.

Returns

Returns the SKData wrapping the encoded pixmap.

Encode(SKWebpEncoderOptions)

Encodes the pixmap as a WEBP.

public SkiaSharp.SKData Encode (SkiaSharp.SKWebpEncoderOptions options);

Parameters

options
SKWebpEncoderOptions

The options to use when creating the encoder.

Returns

Returns the SKData wrapping the encoded pixmap.

Encode(SKWStream, SKPixmap, SKEncodedImageFormat, Int32)

Encodes the pixmap using the specified format.

public static bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKPixmap src, SkiaSharp.SKEncodedImageFormat encoder, int quality);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

src
SKPixmap

The pixmap to encode.

encoder
SKEncodedImageFormat

The file format used to encode the pixmap.

quality
Int32

The quality level to use for the pixmap.

Returns

Returns true on success, or false if there was an error.

Encode(SKJpegEncoderOptions)

Encodes the pixmap as a JPEG.

public SkiaSharp.SKData Encode (SkiaSharp.SKJpegEncoderOptions options);

Parameters

options
SKJpegEncoderOptions

The options to use when creating the encoder.

Returns

Returns the SKData wrapping the encoded pixmap.

Encode(SKWStream, SKPngEncoderOptions)

Encodes the pixmap as a PNG.

public bool Encode (SkiaSharp.SKWStream dst, SkiaSharp.SKPngEncoderOptions options);

Parameters

dst
SKWStream

The stream to write the encoded pixmap to.

options
SKPngEncoderOptions

The options to use when creating the encoder.

Returns

Returns true on success, or false if there was an error.

Applies to