Class GeoImage
public class GeoImage : IDisposable
- Inheritance
-
GeoImage
- Implements
- Inherited Members
Constructors
GeoImage()
Initializes a new instance of the GeoImage class.
public GeoImage()
- See Also
GeoImage(SKBitmap)
Initializes a new instance of the GeoImage class.
public GeoImage(SKBitmap skBitmap)
Parameters
skBitmapSKBitmapA SKBitmap object, it's an cross-platform bitmap object from SKIA-Sharp
- See Also
GeoImage(byte[])
Initializes a new instance of the GeoImage class.
public GeoImage(byte[] bytes)
Parameters
bytesbyte[]The bytes.
- See Also
GeoImage(Stream)
Initializes a new instance of the GeoImage class.
public GeoImage(Stream stream)
Parameters
streamStreamThe stream.
- See Also
GeoImage(int, int)
Initializes a new instance of the GeoImage class.
public GeoImage(int width, int height)
Parameters
- See Also
GeoImage(string)
Initializes a new instance of the GeoImage class.
public GeoImage(string pathFilename)
Parameters
pathFilenamestringThe path filename.
- See Also
Properties
Height
Gets the height.
public int Height { get; }
Property Value
- int
The height.
- See Also
NativeImage
public SKBitmap NativeImage { get; }
Property Value
- SKBitmap
- See Also
Opacity
Gets or sets the opacity.
public float Opacity { get; set; }
Property Value
- float
The opacity.
- See Also
PathFilename
Gets the path filename.
public string PathFilename { get; }
Property Value
- string
The path filename.
- See Also
Width
Gets the width.
public int Width { get; }
Property Value
- int
The width.
- See Also
Methods
Clear(GeoColor)
Clears the specified color.
public void Clear(GeoColor color)
Parameters
colorGeoColorThe color.
- See Also
Clip(DrawingRectangle, int, int)
public GeoImage Clip(DrawingRectangle clippingRectangle, int clippingWidth, int clippingHeight)
Parameters
clippingRectangleDrawingRectangleclippingWidthintclippingHeightint
Returns
- See Also
CreateCustomizedImage(int, int, GeoColorType, GeoAlphaType)
Creates the customized image.
public static GeoImage CreateCustomizedImage(int width, int height, GeoColorType colorType, GeoAlphaType alphaType)
Parameters
widthintThe width.
heightintThe height.
colorTypeGeoColorTypeType of the color.
alphaTypeGeoAlphaTypeType of the alpha.
Returns
- See Also
Crop(DrawingRectangle)
Cuts the specified source rect.
public GeoImage Crop(DrawingRectangle srcRect)
Parameters
srcRectDrawingRectangleThe source rect.
Returns
- See Also
Dispose()
This method implements the IDispose method. This method is the concrete wrapper for the abstract method DisposeCore.
public void Dispose()
- See Also
Dispose(bool)
This method disposes all the unmanaged resource in the tile.
protected virtual void Dispose(bool disposing)
Parameters
disposingbool
Remarks
When implementing this method, consider the stop the background threading when drawing asynchronously.
- See Also
DrawImage(GeoImage, float, float)
Combines the images.
public void DrawImage(GeoImage geoImage, float pointX, float pointY)
Parameters
- See Also
DrawText(string, GeoFont, GeoBrush, ScreenPointF[])
Appends the text.
public void DrawText(string text, GeoFont font, GeoBrush fillBrush, ScreenPointF[] points)
Parameters
textstringThe text.
fontGeoFontThe font.
fillBrushGeoBrushThe fill brush.
pointsScreenPointF[]The points.
- See Also
~GeoImage()
Finalizer of this tile object.
protected ~GeoImage()
- See Also
GetImageBytes(GeoImageFormat, int)
Gets the image bytes.
public byte[] GetImageBytes(GeoImageFormat imageFormat = GeoImageFormat.Png, int imageQuality = 80)
Parameters
imageFormatGeoImageFormatThe image format.
imageQualityintThe image quality.
Returns
- byte[]
- See Also
GetImageStream(GeoImageFormat, int)
Gets the image stream.
public Stream GetImageStream(GeoImageFormat imageFormat = GeoImageFormat.Png, int imageQuality = 80)
Parameters
imageFormatGeoImageFormatThe image format.
imageQualityintThe image quality.
Returns
- See Also
GetIntPtr()
Gets the pixels.
public nint GetIntPtr()
Returns
- See Also
Save(Stream, GeoImageFormat, int)
Saves the specified stream.
public void Save(Stream stream, GeoImageFormat imageFormat, int quality = 80)
Parameters
streamStreamThe stream.
imageFormatGeoImageFormatThe image format.
qualityintThe quality.
- See Also
Save(string, GeoImageFormat, int)
Saves the specified file path.
public void Save(string filePath, GeoImageFormat imageFormat = GeoImageFormat.Png, int quality = 80)
Parameters
filePathstringThe file path.
imageFormatGeoImageFormatThe image format.
qualityintThe quality.
- See Also
Scale(int, int)
Scales the specified width.
public GeoImage Scale(int targetWidth, int targetHeight)
Parameters
Returns
- See Also
SetPixels(GeoColor[])
Sets the pixels.
public void SetPixels(GeoColor[] pixels)
Parameters
pixelsGeoColor[]The pixels.
- See Also