Method
MaplibreNativeFfiRenderSessiondetach_async
Declaration [src]
void
maplibre_native_ffi_render_session_detach_async (
MaplibreNativeFfiRenderSession* self,
GAsyncReadyCallback callback,
gpointer user_data
)
Description [src]
Detaches the session from its map and frees its graphics objects.
Release every acquired frame first. Pending frame demands finish with
MAPLIBRE_NATIVE_FFI_RENDER_RESULT_TARGET_NOT_READY. Once the detach
completes, the library no longer uses your graphics objects, and you can
attach another session to the map. Release the session afterward.
See mln_render_session_detach in the
C API reference.
It fails with these errors:
MAPLIBRE_NATIVE_FFI_ERROR_TARGET_LOSTwhen the session loses its target before the detach runs.
This method completes asynchronously. Use maplibre_native_ffi_render_session_detach_finish() inside the GAsyncReadyCallback to obtain the result of the operation.
Parameters
callback-
Type:
GAsyncReadyCallbackThe callback to call when the call finishes.
The argument can be NULL. user_data-
Type:
gpointerThe data to pass to
callback.The argument can be NULL.The data is owned by the caller of the method.