Bearbeiten

Freigeben über


SkiaSharp Namespace

SkiaSharp is a 2D graphics engine powered by the Skia library.

Classes

GRBackendRenderTarget

Wrap an existing render target created by the client in the 3D API.

GRBackendTexture

Wrap an existing texture created by the client in the 3D API.

GRContext

Represents an underlying backend 3D API context.

GRGlInterface

The GRGlInterface is used to interface with OpenGL.

GRRecordingContext
GRSharpVkBackendContext
GRVkBackendContext
GRVkExtensions
GRVkExtensionsSharpVkExtensions
SK3dView

A utility class that can be used to create 3D transformations.

SKAbstractManagedStream

Represents a SKStreamAsset (a seekable, rewindable Skia stream).

SKAbstractManagedWStream

Represents a SKWStream (a writeable Skia stream).

SKAutoCanvasRestore

Convenience class used to restore the canvas state in a using statement.

SKAutoCoInitialize

Convenience class used to automatically initialize and uninitialize COM on supported platforms.

SKAutoMaskFreeImage

Convenience class used to automatically free the image data for a mask in a using statement.

SKBitmap

The SKBitmap specifies a raster bitmap.

SKCanvas

Encapsulates all of the state about drawing into a device (bitmap or surface).

SKCodec

An abstraction layer directly on top of an image codec.

SKColorFilter

Color filters for use with the ColorFilter property of a SKPaint.

SKColorSpace

Represents a color space.

SKColorSpaceIccProfile
SKColorTable

Holds a premultiplied color table for indexed 8-bit bitmaps.

SKData

The SKData holds an immutable data buffer.

SKDocument

A high-level API for creating a document-based canvas.

SKDrawable

Represents the base class for objects that draw into SKCanvas.

SKDynamicMemoryWStream

A writeable, dynamically-sized, memory-based stream.

SKFileStream

A seekable stream backed by a file on the file system.

SKFileWStream

A writeable stream backed by a file on the file system.

SKFont
SKFontManager

Manages a collection of fonts.

SKFontStyle

Represents a particular style (bold, italic, condensed) of a typeface.

SKFontStyleSet

Represets the set of styles for a particular font family.

SKFrontBufferedManagedStream

A read-only stream that buffers the specified first chunk of bytes.

SKFrontBufferedStream

A read-only stream that buffers the specified first chunk of bytes.

SKGraphics
SKHorizontalRunBuffer
SkiaExtensions

Convenience methods for SKPixelGeometry.

SkiaSharpVersion
SKImage

An abstraction for drawing a rectangle of pixels.

SKImageFilter

Image filters for use with the ImageFilter property of a SKPaint.

SKImageFilter.CropRect

The rectangle to which the output processing of an SKImageFilter will be limited.

SKManagedPixelSerializer

Represents a mechanism for serializing pixels.

SKManagedStream

Wraps a Stream into a SKStreamAsset (a seekable, rewindable Skia stream)

SKManagedWStream

Wraps a Stream into a SKWStream (a writeable Skia stream)

SKMaskFilter

Mask filters perform transformations on an alpha-channel mask before drawing. A mask filter is set using the MaskFilter property on SKPaint type.

SKMatrix44

A 3D, 4x4 matrix.

SKMemoryStream

A memory-based stream.

SKNativeObject

Represents a native object.

SKNoDrawCanvas

A type of SKCanvas that provides a base type for canvases that do not need to rasterize.

SKNWayCanvas

A type of SKCanvas that draws to multiple canvases at the same time.

SKObject

Represents a tracked native object.

SKOverdrawCanvas

A canvas that captures all drawing commands, and rather than draw the actual content, it increments the alpha channel of each pixel every time it would have been touched by a draw call.

SKPaint

Holds the style and color information about how to draw geometries, text and bitmaps.

SKPath

A compound geometric path.

SKPath.Iterator

Iterator object to scan the all of the segments (lines, quadratics, cubics) of each contours in a path.

SKPath.OpBuilder

Perform a series of path operations, optimized for unioning many paths together.

SKPath.RawIterator

Iterator object to scan through the verbs in the path, providing the associated points.

SKPathEffect

The base class for objects in the SKPaint that affect the geometry of a drawing primitive before it is transformed by the canvas' matrix and drawn.

SKPathMeasure

Represents a type that can be used to calculate the length of, and segments of, a path.

SKPicture

Recorded drawing operations made to a SKCanvas to be played back at a later time.

SKPictureRecorder

The picture recorder is used to record drawing operations made to a SKCanvas and stored in a SKPicture.

SKPixelSerializer

Represents a mechanism for serializing pixels.

SKPixmap

Pairs SKImageInfo with actual pixels and rowbytes.

SKPositionedRunBuffer
SKRegion

Encapsulates the geometric region used to specify clipping areas for drawing.

SKRegion.ClipIterator
SKRegion.RectIterator
SKRegion.SpanIterator
SKRotationScaleRunBuffer
SKRoundRect

Represents a rounded rectangle with a potentially different radii for each corner.

SKRunBuffer
SKRuntimeEffect
SKRuntimeEffectChildren
SKRuntimeEffectUniforms
SKShader

Shaders specify the source color(s) for what is being drawn in the SKPaint.

SKStream

An abstraction for a source of bytes, which can be backed by memory, or a file, or something else.

SKStreamAsset

An abstract, seekable stream with a known length.

SKStreamMemory

An abstract, memory-based stream.

SKStreamRewindable

An abstract, rewindable stream.

SKStreamSeekable

An abstract, rewindable stream that supports the seek operation.

SKSurface

Represents the backend/results of drawing to a canvas.

SKSurfaceProperties

Describes properties and constraints of a given SKSurface.

SKSvgCanvas

A specialized SKCanvas which generates SVG commands from its draw calls.

SKSwizzle

Various utility methods for when swizzling pixels.

SKTextBlob

Represents multiple text runs of glyphs and positions.

SKTextBlobBuilder

A builder object that is used to create a SKTextBlob.

SKTraceMemoryDump
SKTypeface

Represents a specific typeface and intrinsic style of a font.

SKVertices

Represents an immutable set of vertex data that can be used with DrawVertices(SKVertices, SKBlendMode, SKPaint).

SKWStream

An abstraction for writing a stream of bytes, which can be backed by memory, or a file, or something else.

SKXmlStreamWriter

A stream-based XML writer.

SKXmlWriter

An abstract, XML writer.

StringUtilities

Various utility methods for when working with strings and text.

Structs

GRBackendRenderTargetDesc

Wrap an existing render target created by the client in the 3D API with an underlying GRRenderTarget object.

GRBackendTextureDesc

Wrap an existing texture created by the client in the 3D API with an underlying GRTexture object.

GRContextOptions

Represents the collection of options for the construction of a context.

GRGlBackendTextureDesc

Wrap an existing OpenGL texture created by the client in the 3D API with an underlying GRTexture object.

GRGlFramebufferInfo

Represents a handle to an existing OpenGL framebuffer.

GRGlTextureInfo

Represents a handle to an existing OpenGL texture.

GRVkAlloc
GRVkImageInfo
GrVkYcbcrConversionInfo
SKCodecFrameInfo

Information about individual frames in a multi-framed image.

SKCodecOptions

Additional options to pass to GetPixels(SKImageInfo, IntPtr, SKCodecOptions) or one of the overloads that accepts a SKCodecOptions.

SKColor

32-bit ARGB unpremultiplied color value.

SKColorF

16-bit, floating-point, ARGB unpremultiplied color value.

SKColors

Definitions for some common color names.

SKColorSpacePrimaries

Describes a color gamut with primaries and a white point.

SKColorSpaceTransferFn

Represents the coefficients for a common transfer function equation.

SKColorSpaceXyz
SKDocumentPdfMetadata

Optional metadata to be passed into the PDF factory function.

SKEncodedInfo

Describes the encoded image information.

SKFontMetrics

Structure to represent measurements for a font.

SKHighContrastConfig

High contrast configuration settings for use with CreateHighContrast(SKHighContrastConfig).

SKImageInfo

Describe an image's dimensions and pixel type.

SKJpegEncoderOptions

Options to control the JPEG encoding.

SKLattice

Specifies coordinates to divide a bitmap into (XDivs * YDivs) rectangles.

SKMask

A mask is used to describe alpha bitmaps, either 1-bit, 8-bit, or the 3-channel 3D format.

SKMatrix

A 3x3 transformation matrix with perspective.

SKPMColor

32-bit ARGB premultiplied color value.

SKPngEncoderOptions

Options to control the PNG encoding.

SKPoint

Represents an ordered pair of floating-point x- and y-coordinates that defines a point in a two-dimensional plane.

SKPoint3

Represents an ordered pair of floating-point x-, y- and z-coordinates that defines a point in a three-dimensional plane.

SKPointI

Represents an ordered pair of integer x- and y-coordinates that defines a point in a two-dimensional plane.

SKRect

Stores a set of four floating-point numbers that represent the upper-left corner and lower-right corner of a rectangle.

SKRectI

Stores a set of four integers that represent the upper-left corner and lower-right corner of a rectangle.

SKRotationScaleMatrix
SKRuntimeEffectUniform
SKSize

Stores an ordered pair of floating-point numbers describing the width and height of a rectangle.

SKSizeI

Stores an ordered pair of integers describing the width and height of a rectangle.

SKSurfaceProps

Describes properties and constraints of a given SKSurface.

SKWebpEncoderOptions

Options to control the WEBP encoding.

Enums

GRBackend

Possible 3D APIs that may be used by Ganesh.

GRBackendState

Various flags for the ResetContext(GRBackendState) method.

GRBackendTextureDescFlags

Additional options for a backend texture.

GRContextOptionsGpuPathRenderers

Various GPU path renderers for use with GRContextOptions.

GRGlBackendState

Various flags for the ResetContext(GRGlBackendState) method when using a OpenGL backend.

GRPixelConfig

Various pixel configurations supported.

GRSurfaceOrigin

The origin of a texture.

SKAlphaType

Describes how to interpret the alpha component of a pixel.

SKBitmapAllocFlags

Flags to use with SKBitmap().

SKBitmapResizeMethod

Channel selector type for the Resize(SKBitmap, SKBitmap, SKBitmapResizeMethod) method or the Resize(SKPixmap, SKPixmap, SKBitmapResizeMethod) method.

SKBlendMode

Predefined blend modes.

SKBlurMaskFilterFlags

Flags to use with CreateBlur(SKBlurStyle, Single).

SKBlurStyle

Blur types for the CreateBlur(SKBlurStyle, Single) method and its overloads.

SKClipOperation

The logical operations that can be performed when combining two regions.

SKCodecAnimationDisposalMethod

Represents how the next frame in the image is based on the current frame.

SKCodecOrigin

The various origins of a bitmap.

SKCodecResult

Used to describe the result of a call to GetPixels(SKImageInfo, IntPtr, SKCodecOptions) or one of the overloads that accepts a SKCodecOptions.

SKCodecScanlineOrder

The orders in which scanlines can be returned.

SKColorChannel
SKColorSpaceFlags

Various flags that are used when creating a SKColorSpace.

SKColorSpaceGamut

Various gamut values for use with a SKColorSpace.

SKColorSpaceRenderTargetGamma

Represents gamma transfer functions.

SKColorSpaceType

The various types of color sapces.

SKColorType

Describes how to interpret the components of a pixel.

SKCropRectFlags

Flags used by the SKImageFilter.CropRect method.

SKDisplacementMapEffectChannelSelectorType

Channel selector type for the CreateDisplacementMapEffect(SKDisplacementMapEffectChannelSelectorType, SKDisplacementMapEffectChannelSelectorType, Single, SKImageFilter, SKImageFilter, SKImageFilter+CropRect) method.

SKDropShadowImageFilterShadowMode

The various types of shadow modes for use with the CreateDropShadow(Single, Single, Single, Single, SKColor, SKDropShadowImageFilterShadowMode, SKImageFilter, SKImageFilter+CropRect) method.

SKEncodedImageFormat

The various formats used by a SKCodec.

SKEncodedInfoAlpha

The various alpha formats used by a SKEncodedInfo.

SKEncodedInfoColor

The various color formats used by a SKEncodedInfo.

SKEncodedOrigin

Represents various origin values returned by Origin.

SKEncoding

Text encoding definition.

SKFilterQuality

Filter quality settings.

SKFontEdging
SKFontHinting
SKFontStyleSlant

Various font slants for use with SKTypeface.

SKFontStyleWeight

Various predefined font weights for use with SKTypeface.

SKFontStyleWidth

Various predefined font widths for use with SKTypeface.

SKHighContrastConfigInvertStyle

Various invert styles for high contrast calculations.

SKImageCachingHint

Hints to image calls where the system might cache computed intermediates.

SKJpegEncoderAlphaOption

Various options to control how alpha should be handled.

SKJpegEncoderDownsample

Various options for the downsampling factor of the U and V components.

SKLatticeFlags

Flags to control how the bitmap lattice is drawn.

SKLatticeRectType

Optional setting per rectangular grid entry to make it transparent, or to fill the grid entry with a color.

SKMaskFormat

Formats that indicate the memory format of the underlying image data of a SKMask.

SKMatrix44TypeMask

Various flags describing the transformations of a SKMatrix44.

SKMatrixConvolutionTileMode

Matrix convolution tile modes for use with CreateMatrixConvolution(SKSizeI, Single[], Single, Single, SKPointI, SKMatrixConvolutionTileMode, Boolean, SKImageFilter, SKImageFilter+CropRect).

SKNamedGamma

Various standard gamma corrections.

SKPaintHinting

Levels of hinting that can be performed.

SKPaintStyle

Indications on how to draw geometry.

SKPath1DPathEffectStyle

How to transform path at each point (based on the current position and tangent).

SKPathAddMode

Controls how a path is added to another path.

SKPathArcSize

Indication for whether the smaller or larger of possible two arcs is drawn.

SKPathConvexity

Convexity for paths.

SKPathDirection

Direction for path contours.

SKPathFillType

Possible path fill type values.

SKPathMeasureMatrixFlags

Flags to indicate how to compute a matrix from a position along a path.

SKPathOp

The logical operations that can be performed when combining two paths using Op(SKPath, SKPathOp).

SKPathSegmentMask

The flags used by SegmentMasks.

SKPathVerb

Verbs contained in an SKPath.

SKPixelGeometry

Describes how LCD strips are organized for each pixel.

SKPngEncoderFilterFlags

Various row filters to use when encoding a PNG.

SKPointMode

Possible values to interpret the incoming array of points for the DrawPoints(SKPointMode, SKPoint[], SKPaint) method.

SKRegionOperation

The logical operations that can be performed when combining two regions.

SKRoundRectCorner

Represents the corners of a rounded rectangle.

SKRoundRectType

Represents the various sub-types of rounded rectangles.

SKShaderTileMode

Indications on how the shader should handle drawing outside the original bounds.

SKStrokeCap

Various options for StrokeCap.

SKStrokeJoin

Join style for stroking operations.

SKSurfacePropsFlags

Flags for the SKSurfaceProps.

SKTextAlign

Possible text alignment values.

SKTextEncoding

Possible text encodings.

SKTransferFunctionBehavior

Various flags to be used with PremulBehavior.

SKTrimPathEffectMode

Represents the type of trimming to perform.

SKTypefaceStyle

Specifies the intrinsic style attributes of a given typeface.

SKVertexMode

Various mode with which to interpret triangles when invoking DrawVertices(SKVertexMode, SKPoint[], SKColor[], SKPaint).

SKWebpEncoderCompression

The various types of compression for WEBP files.

SKZeroInitialized

Whether or not the memory passed to GetPixels(SKImageInfo, IntPtr, SKCodecOptions) (or one of the overloads that accepts a SKCodecOptions) is zero initialized

Delegates

GRGlGetProcDelegate

The delegate that is used when locating the various endpoints of an OpenGL implementation.

GRGlGetProcedureAddressDelegate
GRSharpVkGetProcedureAddressDelegate
GRVkGetProcedureAddressDelegate
SKBitmapReleaseDelegate

The delegate that is used when releasing the memory for a bitmap.

SKDataReleaseDelegate

The delegate that is used when a SKData instance is about to be released.

SKGlyphPathDelegate
SKImageRasterReleaseDelegate

The delegate that is used when releasing the memory for a raster-based image.

SKImageTextureReleaseDelegate

The delegate that is used when releasing the memory for a texture-based image.

SKSurfaceReleaseDelegate

The delegate that is used when releasing the memory for a surface.

Remarks

The SkiaSharp provides a complete set of APIs to render 2D images. Usually you start by creating a surface with SKSurface, obtain an SKCanvas from it, and issue drawing commands there. You can then access the underlying bitmap, or get it encoded as an image.