|
MapLibre Native C API
Public C ABI for the MapLibre Native wrapper.
|
#include <render_target.h>
Data Fields | |
| uint32_t | driver |
| uint32_t | requested_texture_ring_depth |
| uint32_t | producer_sync_kind |
| mln_wake | frame_wake |
| mln_wake | driver_work_wake |
| mln_queue_lock | queue_lock |
Common attachment policy copied before an attach call returns.
Every backend attachment call requires *out_session to be MLN_HANDLE_NULL on entry. MLN_STATUS_OK transfers an ATTACHING session to the caller and accepts its completion. A non-OK return leaves *out_session unchanged and invokes no completion. Hosts may service caller-driver work before attachment completes. A failed completion still requires mln_render_session_detach() or mln_render_session_abandon() before mln_render_session_release().
| uint32_t mln_render_session_attach_options::driver |
One mln_render_driver_kind value. Defaults to MLN_RENDER_DRIVER_CALLER_GRAPHICS_THREAD.
| mln_wake mln_render_session_attach_options::driver_work_wake |
Wakes the graphics receiver when caller-driver work is available, including work that a finished driver result releases.
The host services that work whenever the wake fires, even while it renders no frames, because attach, detach, and queries complete only through service.
| mln_wake mln_render_session_attach_options::frame_wake |
Wakes the receiver when the frame-result queue becomes nonempty.
| uint32_t mln_render_session_attach_options::producer_sync_kind |
Producer synchronization for acquired texture frames. Defaults to MLN_GPU_SYNC_CPU_COMPLETE. MLN_GPU_SYNC_OPENGL_FENCE requires a shared EGL or WGL texture target and a caller-graphics-thread driver. Other targets support only CPU completion and fail an unsupported request.
| mln_queue_lock mln_render_session_attach_options::queue_lock |
Host lock on the graphics queue, disabled by default. Only Vulkan targets accept an enabled lock; other backends fail the attach with MLN_STATUS_UNSUPPORTED.
| uint32_t mln_render_session_attach_options::requested_texture_ring_depth |
Requested slot count of a session-owned texture ring, from one to MLN_TEXTURE_RING_MAX_DEPTH. Private targets grant one slot regardless of this value. A borrowed texture ring's depth is its texture count, so borrowed and other targets ignore this value. Defaults to 2, so the host can retain one frame while the session renders its replacement.