turnip: add tu_wsi.h

Also drop unused x11 and wayland type definitions.

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17811>
This commit is contained in:
Chia-I Wu 2022-07-29 17:05:23 -07:00 committed by Marge Bot
parent 543fac108d
commit 4fc31e4af3
4 changed files with 24 additions and 12 deletions

View file

@ -124,6 +124,7 @@ struct tu_device;
struct tu_image;
struct tu_image_view;
struct tu_instance;
struct tu_physical_device;
struct tu_pipeline_layout;
struct tu_query_pool;
struct tu_render_pass;

View file

@ -45,13 +45,7 @@
#include "tu_shader.h"
#include "tu_suballoc.h"
#include "tu_util.h"
/* Pre-declarations needed for WSI entrypoints */
struct wl_surface;
struct wl_display;
typedef struct xcb_connection_t xcb_connection_t;
typedef uint32_t xcb_visualid_t;
typedef uint32_t xcb_window_t;
#include "tu_wsi.h"
/* Whenever we generate an error, pass it through this function. Useful for
* debugging, where we can break on it. Only call at error site, not when
@ -194,11 +188,6 @@ struct tu_instance
enum tu_debug_flags debug_flags;
};
VkResult
tu_wsi_init(struct tu_physical_device *physical_device);
void
tu_wsi_finish(struct tu_physical_device *physical_device);
bool
tu_instance_extension_supported(const char *name);
uint32_t

View file

@ -23,6 +23,7 @@
* DEALINGS IN THE SOFTWARE.
*/
#include "tu_wsi.h"
#include "tu_private.h"
#include "vk_util.h"

View file

@ -0,0 +1,21 @@
/*
* Copyright © 2016 Red Hat.
* Copyright © 2016 Bas Nieuwenhuizen
* SPDX-License-Identifier: MIT
*
* based in part on anv driver which is:
* Copyright © 2015 Intel Corporation
*/
#ifndef TU_WSI_H
#define TU_WSI_H
#include "tu_common.h"
VkResult
tu_wsi_init(struct tu_physical_device *physical_device);
void
tu_wsi_finish(struct tu_physical_device *physical_device);
#endif /* TU_WSI_H */