gdk: Export feature keys privately

Export these. They will be used in the inspector in later commits.
This commit is contained in:
Matthias Clasen 2024-10-24 23:04:37 -04:00
parent 58ef21514e
commit 06ef33271f
5 changed files with 13 additions and 3 deletions

View File

@ -51,6 +51,12 @@ typedef enum {
GDK_VULKAN_FEATURE_SWAPCHAIN_MAINTENANCE = 1 << 5, GDK_VULKAN_FEATURE_SWAPCHAIN_MAINTENANCE = 1 << 5,
} GdkVulkanFeatures; } GdkVulkanFeatures;
#define GDK_VULKAN_N_FEATURES 6
#ifdef GDK_RENDERING_VULKAN
extern const GdkDebugKey gdk_vulkan_feature_keys[];
#endif
/* Tracks information about the device grab on this display */ /* Tracks information about the device grab on this display */
typedef struct typedef struct
{ {

View File

@ -103,7 +103,7 @@
#define DEFAULT_ALLOWED_APIS GDK_GL_API_GL | GDK_GL_API_GLES #define DEFAULT_ALLOWED_APIS GDK_GL_API_GL | GDK_GL_API_GLES
static const GdkDebugKey gdk_gl_feature_keys[] = { const GdkDebugKey gdk_gl_feature_keys[] = {
{ "debug", GDK_GL_FEATURE_DEBUG, "GL_KHR_debug" }, { "debug", GDK_GL_FEATURE_DEBUG, "GL_KHR_debug" },
{ "base-instance", GDK_GL_FEATURE_BASE_INSTANCE, "GL_ARB_base_instance" }, { "base-instance", GDK_GL_FEATURE_BASE_INSTANCE, "GL_ARB_base_instance" },
{ "buffer-storage", GDK_GL_FEATURE_BUFFER_STORAGE, "GL_EXT_buffer_storage" }, { "buffer-storage", GDK_GL_FEATURE_BUFFER_STORAGE, "GL_EXT_buffer_storage" },

View File

@ -24,6 +24,7 @@
#include "gdkdrawcontextprivate.h" #include "gdkdrawcontextprivate.h"
#include "gdkglversionprivate.h" #include "gdkglversionprivate.h"
#include "gdkdmabufprivate.h" #include "gdkdmabufprivate.h"
#include "gdkdebugprivate.h"
G_BEGIN_DECLS G_BEGIN_DECLS
@ -33,6 +34,10 @@ typedef enum {
GDK_GL_FEATURE_BUFFER_STORAGE = 1 << 2, GDK_GL_FEATURE_BUFFER_STORAGE = 1 << 2,
} GdkGLFeatures; } GdkGLFeatures;
#define GDK_GL_N_FEATURES 3
extern const GdkDebugKey gdk_gl_feature_keys[];
typedef enum { typedef enum {
GDK_GL_NONE = 0, GDK_GL_NONE = 0,
GDK_GL_EGL, GDK_GL_EGL,

View File

@ -35,7 +35,7 @@
#include <math.h> #include <math.h>
#ifdef GDK_RENDERING_VULKAN #ifdef GDK_RENDERING_VULKAN
static const GdkDebugKey gdk_vulkan_feature_keys[] = { const GdkDebugKey gdk_vulkan_feature_keys[] = {
{ "dmabuf", GDK_VULKAN_FEATURE_DMABUF, "Never import Dmabufs" }, { "dmabuf", GDK_VULKAN_FEATURE_DMABUF, "Never import Dmabufs" },
{ "ycbcr", GDK_VULKAN_FEATURE_YCBCR, "Do not support Ycbcr textures (also disables dmabufs)" }, { "ycbcr", GDK_VULKAN_FEATURE_YCBCR, "Do not support Ycbcr textures (also disables dmabufs)" },
{ "semaphore-export", GDK_VULKAN_FEATURE_SEMAPHORE_EXPORT, "Disable sync of exported dmabufs" }, { "semaphore-export", GDK_VULKAN_FEATURE_SEMAPHORE_EXPORT, "Disable sync of exported dmabufs" },

View File

@ -117,4 +117,3 @@ gdk_display_ref_vulkan (GdkDisplay *display,
#endif /* !GDK_RENDERING_VULKAN */ #endif /* !GDK_RENDERING_VULKAN */
G_END_DECLS G_END_DECLS