x11: Avoid including full Vulkan headers.

This dramatically improves compile times of the X11 backend.

Reference Issue #8142.
This commit is contained in:
Ryan C. Gordon
2023-08-25 19:45:45 -04:00
parent 4d2f9f3a32
commit b49d0a607e
3 changed files with 3 additions and 4 deletions

View File

@@ -39,8 +39,6 @@
#include "SDL_x11opengles.h" #include "SDL_x11opengles.h"
#endif #endif
#include "SDL_x11vulkan.h"
/* Initialization/Query functions */ /* Initialization/Query functions */
static int X11_VideoInit(SDL_VideoDevice *_this); static int X11_VideoInit(SDL_VideoDevice *_this);
static void X11_VideoQuit(SDL_VideoDevice *_this); static void X11_VideoQuit(SDL_VideoDevice *_this);

View File

@@ -24,6 +24,7 @@
#include "SDL_x11video.h" #include "SDL_x11video.h"
#include "../SDL_vulkan_internal.h"
#include "SDL_x11vulkan.h" #include "SDL_x11vulkan.h"
#include <X11/Xlib.h> #include <X11/Xlib.h>

View File

@@ -23,11 +23,11 @@
#ifndef SDL_x11vulkan_h_ #ifndef SDL_x11vulkan_h_
#define SDL_x11vulkan_h_ #define SDL_x11vulkan_h_
#include "../SDL_vulkan_internal.h" #include <SDL3/SDL_vulkan.h>
#if defined(SDL_VIDEO_VULKAN) && defined(SDL_VIDEO_DRIVER_X11) #if defined(SDL_VIDEO_VULKAN) && defined(SDL_VIDEO_DRIVER_X11)
/*typedef struct xcb_connection_t xcb_connection_t;*/ typedef struct xcb_connection_t xcb_connection_t;
typedef xcb_connection_t *(*PFN_XGetXCBConnection)(Display *dpy); typedef xcb_connection_t *(*PFN_XGetXCBConnection)(Display *dpy);
int X11_Vulkan_LoadLibrary(SDL_VideoDevice *_this, const char *path); int X11_Vulkan_LoadLibrary(SDL_VideoDevice *_this, const char *path);