pass callback to native pick() and remove pick_ffi

This commit is contained in:
Nick Fisher
2024-03-09 11:17:25 +08:00
parent 6e9a02b5b5
commit 13fa60e8de
5 changed files with 6 additions and 8 deletions

View File

@@ -184,7 +184,7 @@ extern "C"
FLUTTER_PLUGIN_EXPORT int reveal_mesh(void *sceneManager, EntityId asset, const char *meshName);
FLUTTER_PLUGIN_EXPORT void set_post_processing(void *const viewer, bool enabled);
FLUTTER_PLUGIN_EXPORT void set_antialiasing(void *const viewer, bool msaa, bool fxaa, bool taa);
FLUTTER_PLUGIN_EXPORT void pick(void *const viewer, int x, int y, EntityId *entityId);
FLUTTER_PLUGIN_EXPORT void pick(void *const viewer, int x, int y, void (*callback)(EntityId entityId, int x, int y));
FLUTTER_PLUGIN_EXPORT const char *get_name_for_entity(void *const sceneManager, const EntityId entityId);
FLUTTER_PLUGIN_EXPORT EntityId find_child_entity_by_name(void *const sceneManager, const EntityId parent, const char* name);
FLUTTER_PLUGIN_EXPORT int get_entity_count(void *const sceneManager, const EntityId target, bool renderableOnly);