SkiaSharp.Views.Forms.SKGLView Class

A hardware-accelerated view that can be drawn on using SkiaSharp drawing commands.

See Also: SKGLView

Syntax

[Xamarin.Forms.RenderWith(typeof(SkiaSharp.Views.Forms.SKGLViewRenderer))]
public class SKGLView : View

Remarks

Requirements

Namespace: SkiaSharp.Views.Forms
Assembly: SkiaSharp.Views.Forms (in SkiaSharp.Views.Forms.dll)
Assembly Versions: 1.55.0.0, 1.56.0.0, 1.57.0.0, 1.58.0.0, 1.59.0.0

The members of SkiaSharp.Views.Forms.SKGLView are listed below.

See Also: View

Public Constructors

Creates a new instance of the SKGLView view.

Public Fields

static readonly
EnableTouchEventsPropertyBindableProperty. Implements the SKGLView.EnableTouchEvents property, and allows the SKGLView class to bind it to properties on other objects at run time.
static readonly
HasRenderLoopPropertyBindableProperty. Identifies the SKGLView.HasRenderLoop bindable property.

Public Properties

[read-only]
CanvasSizeSKSize. Gets the current canvas size.
EnableTouchEventsBoolean. Gets or sets a value indicating whether or not to enable touch events for this view.
HasRenderLoopBoolean. Gets or sets a value indicating whether the surface is drawn using a render loop.

Public Methods

InvalidateSurface()
Informs the surface that it needs to redraw itself.

Protected Methods

override
OnMeasure(Double, Double) : SizeRequest
Method that is called when a layout measurement happens.
OnPaintSurface(SKPaintGLSurfaceEventArgs)
Implement this to draw on the surface.
OnTouch(SKTouchEventArgs)
Implement this to handle touch events on the surface.

Public Events

PaintSurfaceOccurs when the surface needs to be re-drawn.
TouchOccurs when the the surface received a touch event.