public static Task<Bitmap?> ToBitmapAsync(
this IReadableBitmapData source,
PixelFormat pixelFormat,
IQuantizer quantizer = null,
IDitherer ditherer = null,
TaskConfig asyncConfig = null
)
<ExtensionAttribute>
Public Shared Function ToBitmapAsync (
source As IReadableBitmapData,
pixelFormat As PixelFormat,
Optional quantizer As IQuantizer = Nothing,
Optional ditherer As IDitherer = Nothing,
Optional asyncConfig As TaskConfig = Nothing
) As Task(Of Bitmap)
public:
[ExtensionAttribute]
static Task<Bitmap^>^ ToBitmapAsync(
IReadableBitmapData^ source,
PixelFormat pixelFormat,
IQuantizer^ quantizer = nullptr,
IDitherer^ ditherer = nullptr,
TaskConfig^ asyncConfig = nullptr
)
[<ExtensionAttribute>]
static member ToBitmapAsync :
source : IReadableBitmapData *
pixelFormat : PixelFormat *
?quantizer : IQuantizer *
?ditherer : IDitherer *
?asyncConfig : TaskConfig
(* Defaults:
let _quantizer = defaultArg quantizer null
let _ditherer = defaultArg ditherer null
let _asyncConfig = defaultArg asyncConfig null
*)
-> Task<Bitmap>
This method is not a blocking call even if the MaxDegreeOfParallelism property of the asyncConfig parameter is 1.
ArgumentNullException | source is . |
ArgumentOutOfRangeException | pixelFormat does not specify a valid format. |
ArgumentException | The quantizer palette contains too many colors for the indexed format specified by pixelFormat. |
InvalidOperationException | A deadlock has been detected while attempting to create the result. |