Skip to content

Commit

Permalink
Get wayland surface from the window handle
Browse files Browse the repository at this point in the history
  • Loading branch information
belegdol committed Aug 1, 2023
1 parent 1628329 commit 5dd9584
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/renderer_vk.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@
# import <Metal/Metal.h>
#endif // BX_PLATFORM_OSX

#if WL_EGL_PLATFORM
# include <wayland-egl-backend.h>
#endif

namespace bgfx { namespace vk
{
static char s_viewName[BGFX_CONFIG_MAX_VIEWS][BGFX_CONFIG_MAX_VIEW_NAME];
Expand Down Expand Up @@ -6779,7 +6783,7 @@ VK_DESTROY
sci.pNext = NULL;
sci.flags = 0;
sci.display = (wl_display*)g_platformData.ndt;
sci.surface = (wl_surface*)0xb8a220; //FIXME
sci.surface = (wl_surface*)((wl_egl_window*)g_platformData.nwh)->surface;
result = vkCreateWaylandSurfaceKHR(instance, &sci, allocatorCb, &m_surface);
}
}
Expand Down

0 comments on commit 5dd9584

Please sign in to comment.