remove gnCreateDebugger function

This commit is contained in:
Greg Wells
2025-07-15 09:18:53 -04:00
parent 7722467ceb
commit 8d476781a8
22 changed files with 36 additions and 68 deletions

View File

@@ -1,2 +1,2 @@
#include "vulkan_debugger.h"
#include <instance/vulkan_instance.h>
// #include "vulkan_debugger.h"
// #include <instance/vulkan_instance.h>

View File

@@ -1,7 +1,7 @@
#pragma once
#include <vulkan/vulkan.h>
#include <debugger/gryphn_debugger.h>
// #pragma once
// #include <vulkan/vulkan.h>
// #include <debugger/gryphn_debugger.h>
typedef struct gnPlatformDebugger_t {
VkDebugUtilsMessengerEXT debugMessenger;
} gnPlatformDebugger;
// typedef struct gnPlatformDebugger_t {
// VkDebugUtilsMessengerEXT debugMessenger;
// } gnPlatformDebugger;

View File

@@ -80,8 +80,8 @@ gnReturnCode createInstance(gnInstanceHandle instance, gnInstanceInfo instanceIn
#endif
if (instanceInfo.debugger != NULL) {
for (int i = 0; i < instanceInfo.debugger->info.layerCount; i++) {
if (instanceInfo.debugger->info.layers[i] == GN_DEBUGGER_LAYER_PLATFORM) {
for (int i = 0; i < instanceInfo.debugger->layerCount; i++) {
if (instanceInfo.debugger->layers[i] == GN_DEBUGGER_LAYER_PLATFORM) {
vkStringArrayListAdd(&extensions, VK_EXT_DEBUG_UTILS_EXTENSION_NAME);
const char* validation_layers[1] = { "VK_LAYER_KHRONOS_validation" };
@@ -89,8 +89,8 @@ gnReturnCode createInstance(gnInstanceHandle instance, gnInstanceInfo instanceIn
createInfo.ppEnabledLayerNames = (const char*[]){ "VK_LAYER_KHRONOS_validation" };
vkUserData* userData = malloc(sizeof(vkUserData));
userData->debuggerCallback = instanceInfo.debugger->info.callback;
userData->userData = instanceInfo.debugger->info.userData;
userData->debuggerCallback = instanceInfo.debugger->callback;
userData->userData = instanceInfo.debugger->userData;
VkDebugUtilsMessengerCreateInfoEXT debugCreateInfo = {
.sType = VK_STRUCTURE_TYPE_DEBUG_UTILS_MESSENGER_CREATE_INFO_EXT,

View File

@@ -34,7 +34,7 @@ gnReturnCode createOutputDevice(gnOutputDeviceHandle outputDevice, gnInstanceHan
for (int i = 0; i < deviceCreateInfo.enabledExtensionCount; i++)
if (strcmp(deviceCreateInfo.ppEnabledExtensionNames[i], VK_NV_DESCRIPTOR_POOL_OVERALLOCATION_EXTENSION_NAME) == 0) outputDevice->outputDevice->enabledOversizedDescriptorPools = gnTrue;
if (instance->debugger == NULL)
if (instance->hasDebugger)
deviceCreateInfo.enabledLayerCount = 0;
else {
const char* validation_layers[1] = { "VK_LAYER_KHRONOS_validation" };