GraphicsAPI reference
Class GraphicsDeviceOptions
Namespace: MicroEngine.Graphics.Devices
Assembly: MicroEngine.Graphics.dll
Guide: The graphics device
Device creation options.
public sealed record GraphicsDeviceOptions : IEquatable<GraphicsDeviceOptions>Inheritance
object ← GraphicsDeviceOptions
Implements
IEquatable<GraphicsDeviceOptions>
Constructors
GraphicsDeviceOptions(PresentMode, string?, bool, bool)
Device creation options.
public GraphicsDeviceOptions(PresentMode PresentMode = PresentMode.VSync, string? Api = null, bool Debug = false, bool PreferLowPower = false)Parameters
PresentMode PresentMode
Present mode chosen explicitly (never left to the driver); must be in PresentModes when there is a surface.
Api string?
Preferred underlying API (“direct3d12”, “vulkan”, …) or null for the backend default. Check ApiName after creation.
Debug bool
Enable API validation where available.
PreferLowPower bool
Prefer an integrated adapter.
Properties
Api
Preferred underlying API (“direct3d12”, “vulkan”, …) or null for the backend default. Check ApiName after creation.
public string? Api { get; init; }Property Value
Debug
Enable API validation where available.
public bool Debug { get; init; }Property Value
PreferLowPower
Prefer an integrated adapter.
public bool PreferLowPower { get; init; }Property Value
PresentMode
Present mode chosen explicitly (never left to the driver); must be in PresentModes when there is a surface.
public PresentMode PresentMode { get; init; }Property Value
Methods
<Clone>$()
public GraphicsDeviceOptions <Clone>$()Returns
Deconstruct(out PresentMode, out string?, out bool, out bool)
public void Deconstruct(out PresentMode PresentMode, out string? Api, out bool Debug, out bool PreferLowPower)Parameters
PresentMode PresentMode
Api string?
Debug bool
PreferLowPower bool
Equals(object?)
public override bool Equals(object? obj)Parameters
obj object?
Returns
Equals(GraphicsDeviceOptions?)
public bool Equals(GraphicsDeviceOptions? other)Parameters
other GraphicsDeviceOptions?
Returns
GetHashCode()
public override int GetHashCode()Returns
ToString()
public override string ToString()Returns
Operators
operator ==(GraphicsDeviceOptions?, GraphicsDeviceOptions?)
public static bool operator ==(GraphicsDeviceOptions? left, GraphicsDeviceOptions? right)Parameters
left GraphicsDeviceOptions?
right GraphicsDeviceOptions?
Returns
operator !=(GraphicsDeviceOptions?, GraphicsDeviceOptions?)
public static bool operator !=(GraphicsDeviceOptions? left, GraphicsDeviceOptions? right)Parameters
left GraphicsDeviceOptions?
right GraphicsDeviceOptions?