VK: Cleanup.

This commit is contained in:
Branimir Karadžić 2018-04-09 21:09:52 -07:00
parent 93a1c8171a
commit f92c6625d9
3 changed files with 12 additions and 4 deletions

View File

@ -12,6 +12,7 @@
#include <X11/keysymdef.h>
#include <X11/Xlib.h> // will include X11 which #defines None... Don't mess with order of includes.
#include <X11/Xutil.h>
//#include <X11/Xlib-xcb.h>
#include <bgfx/platform.h>
#include <unistd.h> // syscall
@ -35,7 +36,11 @@ namespace entry
inline void x11SetDisplayWindow(void* _display, uint32_t _window, void* _glx = NULL)
{
bgfx::PlatformData pd;
#if 0
pd.ndt = XGetXCBConnection( (Display*)_display);
#else
pd.ndt = _display;
#endif // 0
pd.nwh = (void*)(uintptr_t)_window;
pd.context = _glx;
pd.backBuffer = NULL;

View File

@ -283,6 +283,7 @@ function exampleProjectDefaults()
"X11",
"GL",
"pthread",
-- "X11-xcb",
}
configuration { "linux-steamlink" }

View File

@ -838,9 +838,10 @@ VK_IMPORT
errorState = ErrorState::InstanceCreated;
BX_TRACE("Instance functions:");
#define VK_IMPORT_INSTANCE_FUNC(_optional, _func) \
#define VK_IMPORT_INSTANCE_FUNC(_optional, _func) \
_func = (PFN_##_func)vkGetInstanceProcAddr(m_instance, #_func); \
BX_TRACE("\t%p " #_func, _func); \
BX_TRACE("\t%p " #_func, _func); \
imported &= _optional || NULL != _func
VK_IMPORT_INSTANCE
#undef VK_IMPORT_INSTANCE_FUNC
@ -852,6 +853,7 @@ VK_IMPORT_INSTANCE
}
m_debugReportCallback = VK_NULL_HANDLE;
if (BX_ENABLED(BGFX_CONFIG_DEBUG) )
{
VkDebugReportCallbackCreateInfoEXT drcb;
@ -3525,8 +3527,8 @@ VK_DESTROY
, shaderSize
);
#else
#include "../examples/runtime/shaders/spv/vert.spv.h"
#include "../examples/runtime/shaders/spv/frag.spv.h"
#include "../examples/runtime/shaders/spirv/vert.spv.h"
#include "../examples/runtime/shaders/spirv/frag.spv.h"
shaderSize = BGFX_CHUNK_MAGIC_VSH == magic
? sizeof(vs_cubes_spv)