diff --git a/src/sokol/c/sokol_imgui.h b/src/sokol/c/sokol_imgui.h index 3e76353..f8f1a7b 100644 --- a/src/sokol/c/sokol_imgui.h +++ b/src/sokol/c/sokol_imgui.h @@ -530,8 +530,8 @@ SOKOL_IMGUI_API_DECL void simgui_render(void); SOKOL_IMGUI_API_DECL simgui_image_t simgui_make_image(const simgui_image_desc_t* desc); SOKOL_IMGUI_API_DECL void simgui_destroy_image(simgui_image_t img); SOKOL_IMGUI_API_DECL simgui_image_desc_t simgui_query_image_desc(simgui_image_t img); -SOKOL_IMGUI_API_DECL void* simgui_imtextureid(simgui_image_t img); -SOKOL_IMGUI_API_DECL simgui_image_t simgui_image_from_imtextureid(void* im_texture_id); +SOKOL_IMGUI_API_DECL uint64_t simgui_imtextureid(simgui_image_t img); +SOKOL_IMGUI_API_DECL simgui_image_t simgui_image_from_imtextureid(uint64_t im_texture_id); SOKOL_IMGUI_API_DECL void simgui_add_focus_event(bool focus); SOKOL_IMGUI_API_DECL void simgui_add_mouse_pos_event(float x, float y); SOKOL_IMGUI_API_DECL void simgui_add_touch_pos_event(float x, float y); @@ -2505,14 +2505,14 @@ SOKOL_API_IMPL simgui_image_desc_t simgui_query_image_desc(simgui_image_t img_id return desc; } -SOKOL_API_IMPL void* simgui_imtextureid(simgui_image_t img) { +SOKOL_API_IMPL uint64_t simgui_imtextureid(simgui_image_t img) { SOKOL_ASSERT(_SIMGUI_INIT_COOKIE == _simgui.init_cookie); - return (void*)(uintptr_t)img.id; + return (uint64_t)(uintptr_t)img.id; } -SOKOL_API_IMPL simgui_image_t simgui_image_from_imtextureid(void* im_texture_id) { +SOKOL_API_IMPL simgui_image_t simgui_image_from_imtextureid(uint64_t im_texture_id) { SOKOL_ASSERT(_SIMGUI_INIT_COOKIE == _simgui.init_cookie); - simgui_image_t img = { (uint32_t)(uintptr_t) im_texture_id }; + simgui_image_t img = { (uint32_t)im_texture_id }; return img; } diff --git a/src/sokol/imgui.d b/src/sokol/imgui.d index 5420771..00ae2e7 100644 --- a/src/sokol/imgui.d +++ b/src/sokol/imgui.d @@ -82,12 +82,12 @@ extern(C) ImageDesc simgui_query_image_desc(Image) @system @nogc nothrow; ImageDesc queryImageDesc(Image img) @trusted @nogc nothrow { return simgui_query_image_desc(img); } -extern(C) void* simgui_imtextureid(Image) @system @nogc nothrow; -scope void* imtextureid(Image img) @trusted @nogc nothrow { +extern(C) ulong simgui_imtextureid(Image) @system @nogc nothrow; +ulong imtextureid(Image img) @trusted @nogc nothrow { return simgui_imtextureid(img); } -extern(C) Image simgui_image_from_imtextureid(void*) @system @nogc nothrow; -Image imageFromImtextureid(scope void* im_texture_id) @trusted @nogc nothrow { +extern(C) Image simgui_image_from_imtextureid(ulong) @system @nogc nothrow; +Image imageFromImtextureid(ulong im_texture_id) @trusted @nogc nothrow { return simgui_image_from_imtextureid(im_texture_id); } extern(C) void simgui_add_focus_event(bool) @system @nogc nothrow;