 |
SkiaSharpBitmapIO Class |
SkiaSharpBitmapIO uses SkiaSharp to support bitmap IO operations.
Inheritance Hierarchy Namespace: Ab4d.SharpEngine.AvaloniaUIAssembly: Ab4d.SharpEngine.AvaloniaUI (in Ab4d.SharpEngine.AvaloniaUI.dll) Version: 2.0.8956+4c7684e186ca1be74e7a284fbe739d9a1b843d3c
Syntaxpublic class SkiaSharpBitmapIO : IBitmapIO
The SkiaSharpBitmapIO type exposes the following members.
Constructors
Properties | Name | Description |
---|
 | ConvertToSupportedFormat |
When true (by default) then the loaded images are converted into a format that is supported by the engine
(32 bit BGRA or RGBA format)
When false then the loader tries to preserve the format of the bitmap (for example 8 bit for grayscale)
but this is not guaranteed and the loader may still convert the image to BGRA.
Also, it is not guaranteed that the image in the original format will be correctly displayed.
|
 | FileNotFoundResolver |
Gets or sets a Func that takes file name of a file that does not exists and returns an existing file name. If file name is not resolved, then null is returned.
|
 | FileStreamResolver |
Gets or sets a Func that takes file name of a file that does not exists and returns a stream to the file. The returned stream is closed after the bitmap is read. If file name is not resolved, then null is returned.
|
Top
Methods | Name | Description |
---|
 | CreateSKBitmap |
CreateSKBitmap method takes the RawImageData and returns the Skia's SKBitmap.
|
  | GetSkiaFormat |
GetSkiaFormat returns the Skia's SKColorType from the Vulkan's format
|
 | IsFileFormatExportSupported |
Returns true when exporting a bitmap to the specified file format that is defined by the fileExtension is supported.
|
 | IsFileFormatImportSupported |
Returns true when importing a bitmap from the specified file format that is defined by the fileExtension is supported.
|
 | IsStreamSupported |
Returns true when methods that take Stream as parameter are supported. When false, then only methods that take fileName are supported.
|
 | LoadBitmap(String) |
Load bitmap into the GpuImageData struct
|
 | LoadBitmap(Stream, String) |
Load bitmap into the GpuImageData struct
|
 | LoadSkBitmap |
LoadSkBitmap methods loads the file with the specified file name and returns a Skia's SKBitmap.
|
 | SaveBitmap(RawImageData, String) |
Save bitmap from the GpuImageData to the specified file.
|
 | SaveBitmap(RawImageData, Stream, String) |
Save bitmap from the GpuImageData to the specified fileStream.
|
 | SaveBitmap(RawImageData, Stream, SKEncodedImageFormat, Int32) |
Save bitmap from the GpuImageData to the specified fileStream and by using special file format options that are defied by the fileFormat and quality parameters.
|
 | SaveBitmap(RawImageData, String, SKEncodedImageFormat, Int32) |
Save bitmap from the GpuImageData to the specified file and by using special file format options that are defied by the fileFormat and quality parameters.
|
Top
See Also