MLSpaceCallbacks
Module: Magic Leap Spaces / Space
A structure containing callbacks for events related to the Space. More...
#include <ml_space.h>
Public Attributes
Type | Name |
---|---|
uint32_t | version |
void()(const MLSpaceLocalizationResult localization_result, void *user_data) | on_localization_changed This callback will be invoked whenever there is an update to the localization status. |
Detailed Description
struct MLSpaceCallbacks;
A structure containing callbacks for events related to the Space.
This structure must be initialized by calling MLSpaceCallbacksInit before use. Application can unregister (stop receiving callbacks) at any time by setting the corresponding callback to NULL.
API Level:
- 26
Public Attributes Documentation
version
uint32_t version;
Version of the structure.
on_localization_changed
void(*)(const MLSpaceLocalizationResult *localization_result, void *user_data) on_localization_changed;
This callback will be invoked whenever there is an update to the localization status.
Type | Description |
---|---|
void()(const MLSpaceLocalizationResult localization_result, void *user_data) | )(const MLSpaceLocalizationResult localization_result, void user_data) |
Parameters
localization_result | Information about the localization status. | |
user_data | Pointer to user context data as set by MLSpaceSetCallbacks (can be NULL). |
Localization events can occur when the application requests for localization via MLSpaceRequestLocalization or due to other events outside the control of the app such as head tracking failure, localization loss.