Table of Contents

Struct RenderSessionSnapshot

Namespace
Maplibre.NativeFfi
Assembly
Maplibre.NativeFfi.dll

The state of a render session at one moment.

public readonly record struct RenderSessionSnapshot : IEquatable<RenderSessionSnapshot>
Implements
Inherited Members

Remarks

See mln_render_session_snapshot in the C API reference.

Constructors

RenderSessionSnapshot(RenderSessionState, LogicalExtent, ulong, ulong, uint, Status, bool)

The state of a render session at one moment.

public RenderSessionSnapshot(RenderSessionState State, LogicalExtent Extent, ulong Generation, ulong FrameGeneration, uint AcquiredFrameCount, Status FailureStatus, bool HasTarget)

Parameters

State RenderSessionState
Extent LogicalExtent

The target's logical size, and the map's scale factor.

Generation ulong
FrameGeneration ulong
AcquiredFrameCount uint
FailureStatus Status

Status.Ok until the session fails. Then Status.TargetLost when it failed because it lost its target, or Status.NativeError when it failed for another reason.

HasTarget bool

Whether the session is attached and has a target to render to. It's false from when RenderSessionHandle.ReleaseTargetAsync() completes until you give the session a new target.

Remarks

See mln_render_session_snapshot in the C API reference.

Properties

AcquiredFrameCount

public uint AcquiredFrameCount { get; init; }

Property Value

uint

Extent

The target's logical size, and the map's scale factor.

public LogicalExtent Extent { get; init; }

Property Value

LogicalExtent

FailureStatus

Status.Ok until the session fails. Then Status.TargetLost when it failed because it lost its target, or Status.NativeError when it failed for another reason.

public Status FailureStatus { get; init; }

Property Value

Status

FrameGeneration

public ulong FrameGeneration { get; init; }

Property Value

ulong

Generation

public ulong Generation { get; init; }

Property Value

ulong

HasTarget

Whether the session is attached and has a target to render to. It's false from when RenderSessionHandle.ReleaseTargetAsync() completes until you give the session a new target.

public bool HasTarget { get; init; }

Property Value

bool

State

public RenderSessionState State { get; init; }

Property Value

RenderSessionState