Tip
See the Remarks section of the ConvertPixelFormat(SKBitmap, IQuantizer, IDitherer, SKColorType, SKAlphaType, WorkingColorSpace) method for more details.
public static Task<SKBitmap?> ConvertPixelFormatAsync(
this SKBitmap bitmap,
IQuantizer? quantizer,
IDitherer? ditherer = null,
SKColorType colorType = SKColorType.Unknown,
SKAlphaType alphaType = SKAlphaType.Unknown,
WorkingColorSpace targetColorSpace = WorkingColorSpace.Default,
TaskConfig? asyncConfig = null
)<ExtensionAttribute>
Public Shared Function ConvertPixelFormatAsync (
bitmap As SKBitmap,
quantizer As IQuantizer,
Optional ditherer As IDitherer = Nothing,
Optional colorType As SKColorType = SKColorType.Unknown,
Optional alphaType As SKAlphaType = SKAlphaType.Unknown,
Optional targetColorSpace As WorkingColorSpace = WorkingColorSpace.Default,
Optional asyncConfig As TaskConfig = Nothing
) As Task(Of SKBitmap)public:
[ExtensionAttribute]
static Task<SKBitmap^>^ ConvertPixelFormatAsync(
SKBitmap^ bitmap,
IQuantizer^ quantizer,
IDitherer^ ditherer = nullptr,
SKColorType colorType = SKColorType::Unknown,
SKAlphaType alphaType = SKAlphaType::Unknown,
WorkingColorSpace targetColorSpace = WorkingColorSpace::Default,
TaskConfig^ asyncConfig = nullptr
)[<ExtensionAttribute>]
static member ConvertPixelFormatAsync :
bitmap : SKBitmap *
quantizer : IQuantizer *
?ditherer : IDitherer *
?colorType : SKColorType *
?alphaType : SKAlphaType *
?targetColorSpace : WorkingColorSpace *
?asyncConfig : TaskConfig
(* Defaults:
let _ditherer = defaultArg ditherer null
let _colorType = defaultArg colorType SKColorType.Unknown
let _alphaType = defaultArg alphaType SKAlphaType.Unknown
let _targetColorSpace = defaultArg targetColorSpace WorkingColorSpace.Default
let _asyncConfig = defaultArg asyncConfig null
*)
-> Task<SKBitmap> This method is not a blocking call even if the MaxDegreeOfParallelism property of the asyncConfig parameter is 1.
| ArgumentNullException | bitmap is . |
| ArgumentOutOfRangeException | colorType, alphaType or targetColorSpace does not specify a defined value. |