• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  *
3  * Copyright (c) 2016-2021 The Khronos Group Inc.
4  * Copyright (c) 2016-2021 Valve Corporation
5  * Copyright (c) 2016-2021 LunarG, Inc.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  *     http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  * Author: Mark Lobodzinski <mark@lunarg.com>
20  * Author: Charles Giessen <charles@lunarg.com>
21  *
22  */
23 #pragma once
24 
25 #include <stdbool.h>
26 #include <vulkan/vulkan.h>
27 
28 // Linked list node for tree of debug callbacks
29 typedef struct VkDebugReportContent {
30     VkDebugReportCallbackEXT msgCallback;
31     PFN_vkDebugReportCallbackEXT pfnMsgCallback;
32     VkFlags msgFlags;
33 } VkDebugReportContent;
34 
35 typedef struct VkDebugUtilsMessengerContent {
36     VkDebugUtilsMessengerEXT messenger;
37     VkDebugUtilsMessageSeverityFlagsEXT messageSeverity;
38     VkDebugUtilsMessageTypeFlagsEXT messageType;
39     PFN_vkDebugUtilsMessengerCallbackEXT pfnUserCallback;
40 } VkDebugUtilsMessengerContent;
41 
42 typedef struct VkLayerDbgFunctionNode_ {
43     bool is_messenger;
44     union {
45         VkDebugReportContent report;
46         VkDebugUtilsMessengerContent messenger;
47     };
48     void *pUserData;
49     struct VkLayerDbgFunctionNode_ *pNext;
50 } VkLayerDbgFunctionNode;
51