Skip to main content

Class GraphicsBackendOptions

Namespace: VelloSharp.Avalonia.Core.Options
Assembly: VelloSharp.Avalonia.Core.dll

Top-level configuration consumed by Avalonia host applications when selecting a renderer.

public sealed class GraphicsBackendOptions

Inheritance​

object ← GraphicsBackendOptions

Inherited Members​

object.Equals(object?), object.Equals(object?, object?), object.GetHashCode(), object.GetType(), object.ReferenceEquals(object?, object?), object.ToString()

Constructors​

GraphicsBackendOptions(IEnumerable<GraphicsBackendKind>, GraphicsFeatureSet, GraphicsPresentationOptions)​

Initializes a new instance of .

public GraphicsBackendOptions(IEnumerable<GraphicsBackendKind> preferredBackends, GraphicsFeatureSet features, GraphicsPresentationOptions presentation)

Parameters​

preferredBackends IEnumerable<GraphicsBackendKind>

features GraphicsFeatureSet

presentation GraphicsPresentationOptions

Properties​

Default​

Provides a canonical configuration favouring Vello first, then Skia GPU, then Skia CPU.

public static GraphicsBackendOptions Default { get; }

Property Value​

GraphicsBackendOptions

Features​

Gets the feature toggle configuration.

public GraphicsFeatureSet Features { get; }

Property Value​

GraphicsFeatureSet

PreferredBackends​

Gets the ordered list of preferred backends.

public IReadOnlyList<GraphicsBackendKind> PreferredBackends { get; }

Property Value​

IReadOnlyList<GraphicsBackendKind>

Presentation​

Gets the presentation preferences shared by all devices.

public GraphicsPresentationOptions Presentation { get; }

Property Value​

GraphicsPresentationOptions

Methods​

ToDeviceOptions(GraphicsBackendKind)​

Creates device options for the requested backend using the shared features and presentation.

public GraphicsDeviceOptions ToDeviceOptions(GraphicsBackendKind backend)

Parameters​

backend GraphicsBackendKind

Returns​

GraphicsDeviceOptions