demandFrame method
- FrameDemand demand
Asks the session to render a frame.
The frame shows the map commands that you sent before the call, except the changes that an open command group holds back.
You can call it once the attach call returns. While the attach runs, the
demand waits for it to complete. Every demand finishes with one frame
result that carries its token, and
RenderSessionHandle.drainFrameResults() takes it. A demand without
FrameDemandFlag.force replaces each pending demand with the same flags.
See mln_render_session_demand_frame in the
C API reference.
Errors:
Status.targetLostorStatus.nativeError, asRenderSessionSnapshot.failureStatusreports, when the session has failed.Status.invalidStatewhen you detached, abandoned, released, or disposed the session, or discarded a frame from every texture of its ring.
Implementation
void demandFrame(FrameDemand demand) => withNativeArena((arena) {
_check(
raw.mln_render_session_demand_frame(
_handle.raw,
_writeFrameDemand(demand, arena),
nativeDiagnostic,
),
);
});