blob: 4dffe3cb3820a9c496e42e7d5f2d363df6705acf [file] [log] [blame]
Tobin Ehlis817736c2014-10-21 10:47:45 -06001/* THIS FILE IS GENERATED. DO NOT EDIT. */
2
3/*
4 * XGL
5 *
6 * Copyright (C) 2014 LunarG, Inc.
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a
9 * copy of this software and associated documentation files (the "Software"),
10 * to deal in the Software without restriction, including without limitation
11 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
12 * and/or sell copies of the Software, and to permit persons to whom the
13 * Software is furnished to do so, subject to the following conditions:
14 *
15 * The above copyright notice and this permission notice shall be included
16 * in all copies or substantial portions of the Software.
17 *
18 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
19 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
20 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
21 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
22 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
23 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
24 * DEALINGS IN THE SOFTWARE.
25 */
26
27#include <stdio.h>
28#include <stdlib.h>
29#include <string.h>
30#include <assert.h>
31#include <pthread.h>
32#include "xglLayer.h"
Tobin Ehlis92dbf802014-10-22 09:06:33 -060033#include "xgl_string_helper.h"
34#include "xgl_struct_string_helper.h"
Tobin Ehlis817736c2014-10-21 10:47:45 -060035
36static XGL_LAYER_DISPATCH_TABLE nextTable;
37static XGL_BASE_LAYER_OBJECT *pCurObj;
38static pthread_once_t tabOnce = PTHREAD_ONCE_INIT;
39
40
41static void initLayerTable()
42{
43 GetProcAddrType fpNextGPA;
44 fpNextGPA = pCurObj->pGPA;
45 assert(fpNextGPA);
46
47 GetProcAddrType fpGetProcAddr = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetProcAddr");
48 nextTable.GetProcAddr = fpGetProcAddr;
49 InitAndEnumerateGpusType fpInitAndEnumerateGpus = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglInitAndEnumerateGpus");
50 nextTable.InitAndEnumerateGpus = fpInitAndEnumerateGpus;
51 GetGpuInfoType fpGetGpuInfo = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetGpuInfo");
52 nextTable.GetGpuInfo = fpGetGpuInfo;
53 CreateDeviceType fpCreateDevice = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateDevice");
54 nextTable.CreateDevice = fpCreateDevice;
55 DestroyDeviceType fpDestroyDevice = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDestroyDevice");
56 nextTable.DestroyDevice = fpDestroyDevice;
57 GetExtensionSupportType fpGetExtensionSupport = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetExtensionSupport");
58 nextTable.GetExtensionSupport = fpGetExtensionSupport;
59 EnumerateLayersType fpEnumerateLayers = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglEnumerateLayers");
60 nextTable.EnumerateLayers = fpEnumerateLayers;
61 GetDeviceQueueType fpGetDeviceQueue = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetDeviceQueue");
62 nextTable.GetDeviceQueue = fpGetDeviceQueue;
63 QueueSubmitType fpQueueSubmit = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglQueueSubmit");
64 nextTable.QueueSubmit = fpQueueSubmit;
65 QueueSetGlobalMemReferencesType fpQueueSetGlobalMemReferences = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglQueueSetGlobalMemReferences");
66 nextTable.QueueSetGlobalMemReferences = fpQueueSetGlobalMemReferences;
67 QueueWaitIdleType fpQueueWaitIdle = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglQueueWaitIdle");
68 nextTable.QueueWaitIdle = fpQueueWaitIdle;
69 DeviceWaitIdleType fpDeviceWaitIdle = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDeviceWaitIdle");
70 nextTable.DeviceWaitIdle = fpDeviceWaitIdle;
71 GetMemoryHeapCountType fpGetMemoryHeapCount = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetMemoryHeapCount");
72 nextTable.GetMemoryHeapCount = fpGetMemoryHeapCount;
73 GetMemoryHeapInfoType fpGetMemoryHeapInfo = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetMemoryHeapInfo");
74 nextTable.GetMemoryHeapInfo = fpGetMemoryHeapInfo;
75 AllocMemoryType fpAllocMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglAllocMemory");
76 nextTable.AllocMemory = fpAllocMemory;
77 FreeMemoryType fpFreeMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglFreeMemory");
78 nextTable.FreeMemory = fpFreeMemory;
79 SetMemoryPriorityType fpSetMemoryPriority = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglSetMemoryPriority");
80 nextTable.SetMemoryPriority = fpSetMemoryPriority;
81 MapMemoryType fpMapMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglMapMemory");
82 nextTable.MapMemory = fpMapMemory;
83 UnmapMemoryType fpUnmapMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglUnmapMemory");
84 nextTable.UnmapMemory = fpUnmapMemory;
85 PinSystemMemoryType fpPinSystemMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglPinSystemMemory");
86 nextTable.PinSystemMemory = fpPinSystemMemory;
87 RemapVirtualMemoryPagesType fpRemapVirtualMemoryPages = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglRemapVirtualMemoryPages");
88 nextTable.RemapVirtualMemoryPages = fpRemapVirtualMemoryPages;
89 GetMultiGpuCompatibilityType fpGetMultiGpuCompatibility = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetMultiGpuCompatibility");
90 nextTable.GetMultiGpuCompatibility = fpGetMultiGpuCompatibility;
91 OpenSharedMemoryType fpOpenSharedMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglOpenSharedMemory");
92 nextTable.OpenSharedMemory = fpOpenSharedMemory;
93 OpenSharedQueueSemaphoreType fpOpenSharedQueueSemaphore = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglOpenSharedQueueSemaphore");
94 nextTable.OpenSharedQueueSemaphore = fpOpenSharedQueueSemaphore;
95 OpenPeerMemoryType fpOpenPeerMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglOpenPeerMemory");
96 nextTable.OpenPeerMemory = fpOpenPeerMemory;
97 OpenPeerImageType fpOpenPeerImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglOpenPeerImage");
98 nextTable.OpenPeerImage = fpOpenPeerImage;
99 DestroyObjectType fpDestroyObject = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDestroyObject");
100 nextTable.DestroyObject = fpDestroyObject;
101 GetObjectInfoType fpGetObjectInfo = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetObjectInfo");
102 nextTable.GetObjectInfo = fpGetObjectInfo;
103 BindObjectMemoryType fpBindObjectMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglBindObjectMemory");
104 nextTable.BindObjectMemory = fpBindObjectMemory;
105 CreateFenceType fpCreateFence = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateFence");
106 nextTable.CreateFence = fpCreateFence;
107 GetFenceStatusType fpGetFenceStatus = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetFenceStatus");
108 nextTable.GetFenceStatus = fpGetFenceStatus;
109 WaitForFencesType fpWaitForFences = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWaitForFences");
110 nextTable.WaitForFences = fpWaitForFences;
111 CreateQueueSemaphoreType fpCreateQueueSemaphore = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateQueueSemaphore");
112 nextTable.CreateQueueSemaphore = fpCreateQueueSemaphore;
113 SignalQueueSemaphoreType fpSignalQueueSemaphore = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglSignalQueueSemaphore");
114 nextTable.SignalQueueSemaphore = fpSignalQueueSemaphore;
115 WaitQueueSemaphoreType fpWaitQueueSemaphore = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWaitQueueSemaphore");
116 nextTable.WaitQueueSemaphore = fpWaitQueueSemaphore;
117 CreateEventType fpCreateEvent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateEvent");
118 nextTable.CreateEvent = fpCreateEvent;
119 GetEventStatusType fpGetEventStatus = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetEventStatus");
120 nextTable.GetEventStatus = fpGetEventStatus;
121 SetEventType fpSetEvent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglSetEvent");
122 nextTable.SetEvent = fpSetEvent;
123 ResetEventType fpResetEvent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglResetEvent");
124 nextTable.ResetEvent = fpResetEvent;
125 CreateQueryPoolType fpCreateQueryPool = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateQueryPool");
126 nextTable.CreateQueryPool = fpCreateQueryPool;
127 GetQueryPoolResultsType fpGetQueryPoolResults = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetQueryPoolResults");
128 nextTable.GetQueryPoolResults = fpGetQueryPoolResults;
129 GetFormatInfoType fpGetFormatInfo = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetFormatInfo");
130 nextTable.GetFormatInfo = fpGetFormatInfo;
131 CreateImageType fpCreateImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateImage");
132 nextTable.CreateImage = fpCreateImage;
133 GetImageSubresourceInfoType fpGetImageSubresourceInfo = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglGetImageSubresourceInfo");
134 nextTable.GetImageSubresourceInfo = fpGetImageSubresourceInfo;
135 CreateImageViewType fpCreateImageView = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateImageView");
136 nextTable.CreateImageView = fpCreateImageView;
137 CreateColorAttachmentViewType fpCreateColorAttachmentView = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateColorAttachmentView");
138 nextTable.CreateColorAttachmentView = fpCreateColorAttachmentView;
139 CreateDepthStencilViewType fpCreateDepthStencilView = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateDepthStencilView");
140 nextTable.CreateDepthStencilView = fpCreateDepthStencilView;
141 CreateShaderType fpCreateShader = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateShader");
142 nextTable.CreateShader = fpCreateShader;
143 CreateGraphicsPipelineType fpCreateGraphicsPipeline = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateGraphicsPipeline");
144 nextTable.CreateGraphicsPipeline = fpCreateGraphicsPipeline;
145 CreateComputePipelineType fpCreateComputePipeline = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateComputePipeline");
146 nextTable.CreateComputePipeline = fpCreateComputePipeline;
147 StorePipelineType fpStorePipeline = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglStorePipeline");
148 nextTable.StorePipeline = fpStorePipeline;
149 LoadPipelineType fpLoadPipeline = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglLoadPipeline");
150 nextTable.LoadPipeline = fpLoadPipeline;
151 CreatePipelineDeltaType fpCreatePipelineDelta = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreatePipelineDelta");
152 nextTable.CreatePipelineDelta = fpCreatePipelineDelta;
153 CreateSamplerType fpCreateSampler = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateSampler");
154 nextTable.CreateSampler = fpCreateSampler;
155 CreateDescriptorSetType fpCreateDescriptorSet = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateDescriptorSet");
156 nextTable.CreateDescriptorSet = fpCreateDescriptorSet;
157 BeginDescriptorSetUpdateType fpBeginDescriptorSetUpdate = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglBeginDescriptorSetUpdate");
158 nextTable.BeginDescriptorSetUpdate = fpBeginDescriptorSetUpdate;
159 EndDescriptorSetUpdateType fpEndDescriptorSetUpdate = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglEndDescriptorSetUpdate");
160 nextTable.EndDescriptorSetUpdate = fpEndDescriptorSetUpdate;
161 AttachSamplerDescriptorsType fpAttachSamplerDescriptors = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglAttachSamplerDescriptors");
162 nextTable.AttachSamplerDescriptors = fpAttachSamplerDescriptors;
163 AttachImageViewDescriptorsType fpAttachImageViewDescriptors = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglAttachImageViewDescriptors");
164 nextTable.AttachImageViewDescriptors = fpAttachImageViewDescriptors;
165 AttachMemoryViewDescriptorsType fpAttachMemoryViewDescriptors = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglAttachMemoryViewDescriptors");
166 nextTable.AttachMemoryViewDescriptors = fpAttachMemoryViewDescriptors;
167 AttachNestedDescriptorsType fpAttachNestedDescriptors = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglAttachNestedDescriptors");
168 nextTable.AttachNestedDescriptors = fpAttachNestedDescriptors;
169 ClearDescriptorSetSlotsType fpClearDescriptorSetSlots = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglClearDescriptorSetSlots");
170 nextTable.ClearDescriptorSetSlots = fpClearDescriptorSetSlots;
171 CreateViewportStateType fpCreateViewportState = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateViewportState");
172 nextTable.CreateViewportState = fpCreateViewportState;
173 CreateRasterStateType fpCreateRasterState = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateRasterState");
174 nextTable.CreateRasterState = fpCreateRasterState;
175 CreateMsaaStateType fpCreateMsaaState = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateMsaaState");
176 nextTable.CreateMsaaState = fpCreateMsaaState;
177 CreateColorBlendStateType fpCreateColorBlendState = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateColorBlendState");
178 nextTable.CreateColorBlendState = fpCreateColorBlendState;
179 CreateDepthStencilStateType fpCreateDepthStencilState = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateDepthStencilState");
180 nextTable.CreateDepthStencilState = fpCreateDepthStencilState;
181 CreateCommandBufferType fpCreateCommandBuffer = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCreateCommandBuffer");
182 nextTable.CreateCommandBuffer = fpCreateCommandBuffer;
183 BeginCommandBufferType fpBeginCommandBuffer = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglBeginCommandBuffer");
184 nextTable.BeginCommandBuffer = fpBeginCommandBuffer;
185 EndCommandBufferType fpEndCommandBuffer = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglEndCommandBuffer");
186 nextTable.EndCommandBuffer = fpEndCommandBuffer;
187 ResetCommandBufferType fpResetCommandBuffer = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglResetCommandBuffer");
188 nextTable.ResetCommandBuffer = fpResetCommandBuffer;
189 CmdBindPipelineType fpCmdBindPipeline = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindPipeline");
190 nextTable.CmdBindPipeline = fpCmdBindPipeline;
191 CmdBindPipelineDeltaType fpCmdBindPipelineDelta = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindPipelineDelta");
192 nextTable.CmdBindPipelineDelta = fpCmdBindPipelineDelta;
193 CmdBindStateObjectType fpCmdBindStateObject = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindStateObject");
194 nextTable.CmdBindStateObject = fpCmdBindStateObject;
195 CmdBindDescriptorSetType fpCmdBindDescriptorSet = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindDescriptorSet");
196 nextTable.CmdBindDescriptorSet = fpCmdBindDescriptorSet;
197 CmdBindDynamicMemoryViewType fpCmdBindDynamicMemoryView = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindDynamicMemoryView");
198 nextTable.CmdBindDynamicMemoryView = fpCmdBindDynamicMemoryView;
199 CmdBindIndexDataType fpCmdBindIndexData = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindIndexData");
200 nextTable.CmdBindIndexData = fpCmdBindIndexData;
201 CmdBindAttachmentsType fpCmdBindAttachments = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBindAttachments");
202 nextTable.CmdBindAttachments = fpCmdBindAttachments;
203 CmdPrepareMemoryRegionsType fpCmdPrepareMemoryRegions = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdPrepareMemoryRegions");
204 nextTable.CmdPrepareMemoryRegions = fpCmdPrepareMemoryRegions;
205 CmdPrepareImagesType fpCmdPrepareImages = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdPrepareImages");
206 nextTable.CmdPrepareImages = fpCmdPrepareImages;
207 CmdDrawType fpCmdDraw = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDraw");
208 nextTable.CmdDraw = fpCmdDraw;
209 CmdDrawIndexedType fpCmdDrawIndexed = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDrawIndexed");
210 nextTable.CmdDrawIndexed = fpCmdDrawIndexed;
211 CmdDrawIndirectType fpCmdDrawIndirect = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDrawIndirect");
212 nextTable.CmdDrawIndirect = fpCmdDrawIndirect;
213 CmdDrawIndexedIndirectType fpCmdDrawIndexedIndirect = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDrawIndexedIndirect");
214 nextTable.CmdDrawIndexedIndirect = fpCmdDrawIndexedIndirect;
215 CmdDispatchType fpCmdDispatch = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDispatch");
216 nextTable.CmdDispatch = fpCmdDispatch;
217 CmdDispatchIndirectType fpCmdDispatchIndirect = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDispatchIndirect");
218 nextTable.CmdDispatchIndirect = fpCmdDispatchIndirect;
219 CmdCopyMemoryType fpCmdCopyMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdCopyMemory");
220 nextTable.CmdCopyMemory = fpCmdCopyMemory;
221 CmdCopyImageType fpCmdCopyImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdCopyImage");
222 nextTable.CmdCopyImage = fpCmdCopyImage;
223 CmdCopyMemoryToImageType fpCmdCopyMemoryToImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdCopyMemoryToImage");
224 nextTable.CmdCopyMemoryToImage = fpCmdCopyMemoryToImage;
225 CmdCopyImageToMemoryType fpCmdCopyImageToMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdCopyImageToMemory");
226 nextTable.CmdCopyImageToMemory = fpCmdCopyImageToMemory;
227 CmdCloneImageDataType fpCmdCloneImageData = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdCloneImageData");
228 nextTable.CmdCloneImageData = fpCmdCloneImageData;
229 CmdUpdateMemoryType fpCmdUpdateMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdUpdateMemory");
230 nextTable.CmdUpdateMemory = fpCmdUpdateMemory;
231 CmdFillMemoryType fpCmdFillMemory = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdFillMemory");
232 nextTable.CmdFillMemory = fpCmdFillMemory;
233 CmdClearColorImageType fpCmdClearColorImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdClearColorImage");
234 nextTable.CmdClearColorImage = fpCmdClearColorImage;
235 CmdClearColorImageRawType fpCmdClearColorImageRaw = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdClearColorImageRaw");
236 nextTable.CmdClearColorImageRaw = fpCmdClearColorImageRaw;
237 CmdClearDepthStencilType fpCmdClearDepthStencil = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdClearDepthStencil");
238 nextTable.CmdClearDepthStencil = fpCmdClearDepthStencil;
239 CmdResolveImageType fpCmdResolveImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdResolveImage");
240 nextTable.CmdResolveImage = fpCmdResolveImage;
241 CmdSetEventType fpCmdSetEvent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdSetEvent");
242 nextTable.CmdSetEvent = fpCmdSetEvent;
243 CmdResetEventType fpCmdResetEvent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdResetEvent");
244 nextTable.CmdResetEvent = fpCmdResetEvent;
245 CmdMemoryAtomicType fpCmdMemoryAtomic = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdMemoryAtomic");
246 nextTable.CmdMemoryAtomic = fpCmdMemoryAtomic;
247 CmdBeginQueryType fpCmdBeginQuery = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdBeginQuery");
248 nextTable.CmdBeginQuery = fpCmdBeginQuery;
249 CmdEndQueryType fpCmdEndQuery = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdEndQuery");
250 nextTable.CmdEndQuery = fpCmdEndQuery;
251 CmdResetQueryPoolType fpCmdResetQueryPool = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdResetQueryPool");
252 nextTable.CmdResetQueryPool = fpCmdResetQueryPool;
253 CmdWriteTimestampType fpCmdWriteTimestamp = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdWriteTimestamp");
254 nextTable.CmdWriteTimestamp = fpCmdWriteTimestamp;
255 CmdInitAtomicCountersType fpCmdInitAtomicCounters = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdInitAtomicCounters");
256 nextTable.CmdInitAtomicCounters = fpCmdInitAtomicCounters;
257 CmdLoadAtomicCountersType fpCmdLoadAtomicCounters = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdLoadAtomicCounters");
258 nextTable.CmdLoadAtomicCounters = fpCmdLoadAtomicCounters;
259 CmdSaveAtomicCountersType fpCmdSaveAtomicCounters = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdSaveAtomicCounters");
260 nextTable.CmdSaveAtomicCounters = fpCmdSaveAtomicCounters;
261 DbgSetValidationLevelType fpDbgSetValidationLevel = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgSetValidationLevel");
262 nextTable.DbgSetValidationLevel = fpDbgSetValidationLevel;
263 DbgRegisterMsgCallbackType fpDbgRegisterMsgCallback = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgRegisterMsgCallback");
264 nextTable.DbgRegisterMsgCallback = fpDbgRegisterMsgCallback;
265 DbgUnregisterMsgCallbackType fpDbgUnregisterMsgCallback = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgUnregisterMsgCallback");
266 nextTable.DbgUnregisterMsgCallback = fpDbgUnregisterMsgCallback;
267 DbgSetMessageFilterType fpDbgSetMessageFilter = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgSetMessageFilter");
268 nextTable.DbgSetMessageFilter = fpDbgSetMessageFilter;
269 DbgSetObjectTagType fpDbgSetObjectTag = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgSetObjectTag");
270 nextTable.DbgSetObjectTag = fpDbgSetObjectTag;
271 DbgSetGlobalOptionType fpDbgSetGlobalOption = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgSetGlobalOption");
272 nextTable.DbgSetGlobalOption = fpDbgSetGlobalOption;
273 DbgSetDeviceOptionType fpDbgSetDeviceOption = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglDbgSetDeviceOption");
274 nextTable.DbgSetDeviceOption = fpDbgSetDeviceOption;
275 CmdDbgMarkerBeginType fpCmdDbgMarkerBegin = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDbgMarkerBegin");
276 nextTable.CmdDbgMarkerBegin = fpCmdDbgMarkerBegin;
277 CmdDbgMarkerEndType fpCmdDbgMarkerEnd = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglCmdDbgMarkerEnd");
278 nextTable.CmdDbgMarkerEnd = fpCmdDbgMarkerEnd;
279 WsiX11AssociateConnectionType fpWsiX11AssociateConnection = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWsiX11AssociateConnection");
280 nextTable.WsiX11AssociateConnection = fpWsiX11AssociateConnection;
281 WsiX11GetMSCType fpWsiX11GetMSC = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWsiX11GetMSC");
282 nextTable.WsiX11GetMSC = fpWsiX11GetMSC;
283 WsiX11CreatePresentableImageType fpWsiX11CreatePresentableImage = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWsiX11CreatePresentableImage");
284 nextTable.WsiX11CreatePresentableImage = fpWsiX11CreatePresentableImage;
285 WsiX11QueuePresentType fpWsiX11QueuePresent = fpNextGPA((XGL_PHYSICAL_GPU) pCurObj->nextObject, (XGL_CHAR *) "xglWsiX11QueuePresent");
286 nextTable.WsiX11QueuePresent = fpWsiX11QueuePresent;
287}
288
289
290XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetGpuInfo(XGL_PHYSICAL_GPU gpu, XGL_PHYSICAL_GPU_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData)
291{
292 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
Tobin Ehlis817736c2014-10-21 10:47:45 -0600293 pCurObj = gpuw;
294 pthread_once(&tabOnce, initLayerTable);
295 XGL_RESULT result = nextTable.GetGpuInfo((XGL_PHYSICAL_GPU)gpuw->nextObject, infoType, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600296 printf("xglGetGpuInfo(gpu = %p, infoType = %s, pDataSize = %i, pData = %p) = %s\n", (void*)gpu, string_XGL_PHYSICAL_GPU_INFO_TYPE(infoType), *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600297 return result;
298}
299
300XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateDevice(XGL_PHYSICAL_GPU gpu, const XGL_DEVICE_CREATE_INFO* pCreateInfo, XGL_DEVICE* pDevice)
301{
302 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
Tobin Ehlis817736c2014-10-21 10:47:45 -0600303 pCurObj = gpuw;
304 pthread_once(&tabOnce, initLayerTable);
305 XGL_RESULT result = nextTable.CreateDevice((XGL_PHYSICAL_GPU)gpuw->nextObject, pCreateInfo, pDevice);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600306 printf("xglCreateDevice(gpu = %p, pCreateInfo = %p, pDevice = %p) = %s\n", (void*)gpu, (void*)pCreateInfo, (void*)*pDevice, string_XGL_RESULT(result));
307 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_device_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600308 return result;
309}
310
311XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDestroyDevice(XGL_DEVICE device)
312{
313 XGL_RESULT result = nextTable.DestroyDevice(device);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600314 printf("xglDestroyDevice(device = %p) = %s\n", (void*)device, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600315 return result;
316}
317
318XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetExtensionSupport(XGL_PHYSICAL_GPU gpu, const XGL_CHAR* pExtName)
319{
320 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
Tobin Ehlis817736c2014-10-21 10:47:45 -0600321 pCurObj = gpuw;
322 pthread_once(&tabOnce, initLayerTable);
323 XGL_RESULT result = nextTable.GetExtensionSupport((XGL_PHYSICAL_GPU)gpuw->nextObject, pExtName);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600324 printf("xglGetExtensionSupport(gpu = %p, pExtName = %p) = %s\n", (void*)gpu, (void*)pExtName, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600325 return result;
326}
327
328XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglEnumerateLayers(XGL_PHYSICAL_GPU gpu, XGL_SIZE maxLayerCount, XGL_SIZE maxStringSize, XGL_CHAR* const* pOutLayers, XGL_SIZE * pOutLayerCount)
329{
330 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
Tobin Ehlis817736c2014-10-21 10:47:45 -0600331 pCurObj = gpuw;
332 pthread_once(&tabOnce, initLayerTable);
333 XGL_RESULT result = nextTable.EnumerateLayers((XGL_PHYSICAL_GPU)gpuw->nextObject, maxLayerCount, maxStringSize, pOutLayers, pOutLayerCount);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600334 printf("xglEnumerateLayers(gpu = %p, maxLayerCount = %i, maxStringSize = %i, pOutLayers = %p, pOutLayerCount = %i) = %s\n", (void*)gpu, maxLayerCount, maxStringSize, (void*)pOutLayers, *pOutLayerCount, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600335 return result;
336}
337
338XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetDeviceQueue(XGL_DEVICE device, XGL_QUEUE_TYPE queueType, XGL_UINT queueIndex, XGL_QUEUE* pQueue)
339{
340 XGL_RESULT result = nextTable.GetDeviceQueue(device, queueType, queueIndex, pQueue);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600341 printf("xglGetDeviceQueue(device = %p, queueType = %s, queueIndex = %i, pQueue = %p) = %s\n", (void*)device, string_XGL_QUEUE_TYPE(queueType), queueIndex, (void*)pQueue, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600342 return result;
343}
344
345XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglQueueSubmit(XGL_QUEUE queue, XGL_UINT cmdBufferCount, const XGL_CMD_BUFFER* pCmdBuffers, XGL_UINT memRefCount, const XGL_MEMORY_REF* pMemRefs, XGL_FENCE fence)
346{
347 XGL_RESULT result = nextTable.QueueSubmit(queue, cmdBufferCount, pCmdBuffers, memRefCount, pMemRefs, fence);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600348 printf("xglQueueSubmit(queue = %p, cmdBufferCount = %i, pCmdBuffers = %p, memRefCount = %i, pMemRefs = %p, fence = %p) = %s\n", (void*)queue, cmdBufferCount, (void*)pCmdBuffers, memRefCount, (void*)pMemRefs, (void*)fence, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600349 return result;
350}
351
352XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglQueueSetGlobalMemReferences(XGL_QUEUE queue, XGL_UINT memRefCount, const XGL_MEMORY_REF* pMemRefs)
353{
354 XGL_RESULT result = nextTable.QueueSetGlobalMemReferences(queue, memRefCount, pMemRefs);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600355 printf("xglQueueSetGlobalMemReferences(queue = %p, memRefCount = %i, pMemRefs = %p) = %s\n", (void*)queue, memRefCount, (void*)pMemRefs, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600356 return result;
357}
358
359XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglQueueWaitIdle(XGL_QUEUE queue)
360{
361 XGL_RESULT result = nextTable.QueueWaitIdle(queue);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600362 printf("xglQueueWaitIdle(queue = %p) = %s\n", (void*)queue, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600363 return result;
364}
365
366XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDeviceWaitIdle(XGL_DEVICE device)
367{
368 XGL_RESULT result = nextTable.DeviceWaitIdle(device);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600369 printf("xglDeviceWaitIdle(device = %p) = %s\n", (void*)device, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600370 return result;
371}
372
373XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetMemoryHeapCount(XGL_DEVICE device, XGL_UINT* pCount)
374{
375 XGL_RESULT result = nextTable.GetMemoryHeapCount(device, pCount);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600376 printf("xglGetMemoryHeapCount(device = %p, pCount = %i) = %s\n", (void*)device, *pCount, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600377 return result;
378}
379
380XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetMemoryHeapInfo(XGL_DEVICE device, XGL_UINT heapId, XGL_MEMORY_HEAP_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData)
381{
382 XGL_RESULT result = nextTable.GetMemoryHeapInfo(device, heapId, infoType, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600383 printf("xglGetMemoryHeapInfo(device = %p, heapId = %i, infoType = %s, pDataSize = %i, pData = %p) = %s\n", (void*)device, heapId, string_XGL_MEMORY_HEAP_INFO_TYPE(infoType), *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600384 return result;
385}
386
387XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglAllocMemory(XGL_DEVICE device, const XGL_MEMORY_ALLOC_INFO* pAllocInfo, XGL_GPU_MEMORY* pMem)
388{
389 XGL_RESULT result = nextTable.AllocMemory(device, pAllocInfo, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600390 printf("xglAllocMemory(device = %p, pAllocInfo = %p, pMem = %p) = %s\n", (void*)device, (void*)pAllocInfo, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600391 return result;
392}
393
394XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglFreeMemory(XGL_GPU_MEMORY mem)
395{
396 XGL_RESULT result = nextTable.FreeMemory(mem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600397 printf("xglFreeMemory(mem = %p) = %s\n", (void*)mem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600398 return result;
399}
400
401XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglSetMemoryPriority(XGL_GPU_MEMORY mem, XGL_MEMORY_PRIORITY priority)
402{
403 XGL_RESULT result = nextTable.SetMemoryPriority(mem, priority);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600404 printf("xglSetMemoryPriority(mem = %p, priority = %p) = %s\n", (void*)mem, (void*)priority, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600405 return result;
406}
407
408XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglMapMemory(XGL_GPU_MEMORY mem, XGL_FLAGS flags, XGL_VOID** ppData)
409{
410 XGL_RESULT result = nextTable.MapMemory(mem, flags, ppData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600411 printf("xglMapMemory(mem = %p, flags = %i, ppData = %p) = %s\n", (void*)mem, flags, (void*)ppData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600412 return result;
413}
414
415XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglUnmapMemory(XGL_GPU_MEMORY mem)
416{
417 XGL_RESULT result = nextTable.UnmapMemory(mem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600418 printf("xglUnmapMemory(mem = %p) = %s\n", (void*)mem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600419 return result;
420}
421
422XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglPinSystemMemory(XGL_DEVICE device, const XGL_VOID* pSysMem, XGL_SIZE memSize, XGL_GPU_MEMORY* pMem)
423{
424 XGL_RESULT result = nextTable.PinSystemMemory(device, pSysMem, memSize, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600425 printf("xglPinSystemMemory(device = %p, pSysMem = %p, memSize = %i, pMem = %p) = %s\n", (void*)device, (void*)pSysMem, memSize, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600426 return result;
427}
428
429XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglRemapVirtualMemoryPages(XGL_DEVICE device, XGL_UINT rangeCount, const XGL_VIRTUAL_MEMORY_REMAP_RANGE* pRanges, XGL_UINT preWaitSemaphoreCount, const XGL_QUEUE_SEMAPHORE* pPreWaitSemaphores, XGL_UINT postSignalSemaphoreCount, const XGL_QUEUE_SEMAPHORE* pPostSignalSemaphores)
430{
431 XGL_RESULT result = nextTable.RemapVirtualMemoryPages(device, rangeCount, pRanges, preWaitSemaphoreCount, pPreWaitSemaphores, postSignalSemaphoreCount, pPostSignalSemaphores);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600432 printf("xglRemapVirtualMemoryPages(device = %p, rangeCount = %i, pRanges = %p, preWaitSemaphoreCount = %i, pPreWaitSemaphores = %p, postSignalSemaphoreCount = %i, pPostSignalSemaphores = %p) = %s\n", (void*)device, rangeCount, (void*)pRanges, preWaitSemaphoreCount, (void*)pPreWaitSemaphores, postSignalSemaphoreCount, (void*)pPostSignalSemaphores, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600433 return result;
434}
435
436XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetMultiGpuCompatibility(XGL_PHYSICAL_GPU gpu0, XGL_PHYSICAL_GPU gpu1, XGL_GPU_COMPATIBILITY_INFO* pInfo)
437{
438 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu0;
Tobin Ehlis817736c2014-10-21 10:47:45 -0600439 pCurObj = gpuw;
440 pthread_once(&tabOnce, initLayerTable);
441 XGL_RESULT result = nextTable.GetMultiGpuCompatibility((XGL_PHYSICAL_GPU)gpuw->nextObject, gpu1, pInfo);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600442 printf("xglGetMultiGpuCompatibility(gpu0 = %p, gpu1 = %p, pInfo = %p) = %s\n", (void*)gpu0, (void*)gpu1, (void*)pInfo, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600443 return result;
444}
445
446XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglOpenSharedMemory(XGL_DEVICE device, const XGL_MEMORY_OPEN_INFO* pOpenInfo, XGL_GPU_MEMORY* pMem)
447{
448 XGL_RESULT result = nextTable.OpenSharedMemory(device, pOpenInfo, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600449 printf("xglOpenSharedMemory(device = %p, pOpenInfo = %p, pMem = %p) = %s\n", (void*)device, (void*)pOpenInfo, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600450 return result;
451}
452
453XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglOpenSharedQueueSemaphore(XGL_DEVICE device, const XGL_QUEUE_SEMAPHORE_OPEN_INFO* pOpenInfo, XGL_QUEUE_SEMAPHORE* pSemaphore)
454{
455 XGL_RESULT result = nextTable.OpenSharedQueueSemaphore(device, pOpenInfo, pSemaphore);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600456 printf("xglOpenSharedQueueSemaphore(device = %p, pOpenInfo = %p, pSemaphore = %p) = %s\n", (void*)device, (void*)pOpenInfo, (void*)pSemaphore, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600457 return result;
458}
459
460XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglOpenPeerMemory(XGL_DEVICE device, const XGL_PEER_MEMORY_OPEN_INFO* pOpenInfo, XGL_GPU_MEMORY* pMem)
461{
462 XGL_RESULT result = nextTable.OpenPeerMemory(device, pOpenInfo, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600463 printf("xglOpenPeerMemory(device = %p, pOpenInfo = %p, pMem = %p) = %s\n", (void*)device, (void*)pOpenInfo, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600464 return result;
465}
466
467XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglOpenPeerImage(XGL_DEVICE device, const XGL_PEER_IMAGE_OPEN_INFO* pOpenInfo, XGL_IMAGE* pImage, XGL_GPU_MEMORY* pMem)
468{
469 XGL_RESULT result = nextTable.OpenPeerImage(device, pOpenInfo, pImage, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600470 printf("xglOpenPeerImage(device = %p, pOpenInfo = %p, pImage = %p, pMem = %p) = %s\n", (void*)device, (void*)pOpenInfo, (void*)pImage, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600471 return result;
472}
473
474XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDestroyObject(XGL_OBJECT object)
475{
476 XGL_RESULT result = nextTable.DestroyObject(object);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600477 printf("xglDestroyObject(object = %p) = %s\n", (void*)object, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600478 return result;
479}
480
481XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetObjectInfo(XGL_BASE_OBJECT object, XGL_OBJECT_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData)
482{
483 XGL_RESULT result = nextTable.GetObjectInfo(object, infoType, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600484 printf("xglGetObjectInfo(object = %p, infoType = %s, pDataSize = %i, pData = %p) = %s\n", (void*)object, string_XGL_OBJECT_INFO_TYPE(infoType), *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600485 return result;
486}
487
488XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBindObjectMemory(XGL_OBJECT object, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
489{
490 XGL_RESULT result = nextTable.BindObjectMemory(object, mem, offset);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600491 printf("xglBindObjectMemory(object = %p, mem = %p, offset = %i) = %s\n", (void*)object, (void*)mem, offset, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600492 return result;
493}
494
495XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateFence(XGL_DEVICE device, const XGL_FENCE_CREATE_INFO* pCreateInfo, XGL_FENCE* pFence)
496{
497 XGL_RESULT result = nextTable.CreateFence(device, pCreateInfo, pFence);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600498 printf("xglCreateFence(device = %p, pCreateInfo = %p, pFence = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pFence, string_XGL_RESULT(result));
499 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_fence_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600500 return result;
501}
502
503XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetFenceStatus(XGL_FENCE fence)
504{
505 XGL_RESULT result = nextTable.GetFenceStatus(fence);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600506 printf("xglGetFenceStatus(fence = %p) = %s\n", (void*)fence, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600507 return result;
508}
509
510XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWaitForFences(XGL_DEVICE device, XGL_UINT fenceCount, const XGL_FENCE* pFences, XGL_BOOL waitAll, XGL_UINT64 timeout)
511{
512 XGL_RESULT result = nextTable.WaitForFences(device, fenceCount, pFences, waitAll, timeout);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600513 printf("xglWaitForFences(device = %p, fenceCount = %i, pFences = %p, waitAll = %u, timeout = %lu) = %s\n", (void*)device, fenceCount, (void*)pFences, waitAll, timeout, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600514 return result;
515}
516
517XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateQueueSemaphore(XGL_DEVICE device, const XGL_QUEUE_SEMAPHORE_CREATE_INFO* pCreateInfo, XGL_QUEUE_SEMAPHORE* pSemaphore)
518{
519 XGL_RESULT result = nextTable.CreateQueueSemaphore(device, pCreateInfo, pSemaphore);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600520 printf("xglCreateQueueSemaphore(device = %p, pCreateInfo = %p, pSemaphore = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pSemaphore, string_XGL_RESULT(result));
521 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_queue_semaphore_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600522 return result;
523}
524
525XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglSignalQueueSemaphore(XGL_QUEUE queue, XGL_QUEUE_SEMAPHORE semaphore)
526{
527 XGL_RESULT result = nextTable.SignalQueueSemaphore(queue, semaphore);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600528 printf("xglSignalQueueSemaphore(queue = %p, semaphore = %p) = %s\n", (void*)queue, (void*)semaphore, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600529 return result;
530}
531
532XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWaitQueueSemaphore(XGL_QUEUE queue, XGL_QUEUE_SEMAPHORE semaphore)
533{
534 XGL_RESULT result = nextTable.WaitQueueSemaphore(queue, semaphore);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600535 printf("xglWaitQueueSemaphore(queue = %p, semaphore = %p) = %s\n", (void*)queue, (void*)semaphore, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600536 return result;
537}
538
539XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateEvent(XGL_DEVICE device, const XGL_EVENT_CREATE_INFO* pCreateInfo, XGL_EVENT* pEvent)
540{
541 XGL_RESULT result = nextTable.CreateEvent(device, pCreateInfo, pEvent);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600542 printf("xglCreateEvent(device = %p, pCreateInfo = %p, pEvent = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pEvent, string_XGL_RESULT(result));
543 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_event_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600544 return result;
545}
546
547XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetEventStatus(XGL_EVENT event)
548{
549 XGL_RESULT result = nextTable.GetEventStatus(event);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600550 printf("xglGetEventStatus(event = %p) = %s\n", (void*)event, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600551 return result;
552}
553
554XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglSetEvent(XGL_EVENT event)
555{
556 XGL_RESULT result = nextTable.SetEvent(event);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600557 printf("xglSetEvent(event = %p) = %s\n", (void*)event, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600558 return result;
559}
560
561XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglResetEvent(XGL_EVENT event)
562{
563 XGL_RESULT result = nextTable.ResetEvent(event);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600564 printf("xglResetEvent(event = %p) = %s\n", (void*)event, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600565 return result;
566}
567
568XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateQueryPool(XGL_DEVICE device, const XGL_QUERY_POOL_CREATE_INFO* pCreateInfo, XGL_QUERY_POOL* pQueryPool)
569{
570 XGL_RESULT result = nextTable.CreateQueryPool(device, pCreateInfo, pQueryPool);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600571 printf("xglCreateQueryPool(device = %p, pCreateInfo = %p, pQueryPool = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pQueryPool, string_XGL_RESULT(result));
572 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_query_pool_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600573 return result;
574}
575
576XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetQueryPoolResults(XGL_QUERY_POOL queryPool, XGL_UINT startQuery, XGL_UINT queryCount, XGL_SIZE* pDataSize, XGL_VOID* pData)
577{
578 XGL_RESULT result = nextTable.GetQueryPoolResults(queryPool, startQuery, queryCount, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600579 printf("xglGetQueryPoolResults(queryPool = %p, startQuery = %i, queryCount = %i, pDataSize = %i, pData = %p) = %s\n", (void*)queryPool, startQuery, queryCount, *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600580 return result;
581}
582
583XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetFormatInfo(XGL_DEVICE device, XGL_FORMAT format, XGL_FORMAT_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData)
584{
585 XGL_RESULT result = nextTable.GetFormatInfo(device, format, infoType, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600586 printf("xglGetFormatInfo(device = %p, format.channelFormat = %s, format.numericFormat = %s, infoType = %i, pDataSize = %i, pData = %p) = %s\n", (void*)device, string_XGL_CHANNEL_FORMAT(format.channelFormat), string_XGL_NUM_FORMAT(format.numericFormat), infoType, *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600587 return result;
588}
589
590XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateImage(XGL_DEVICE device, const XGL_IMAGE_CREATE_INFO* pCreateInfo, XGL_IMAGE* pImage)
591{
592 XGL_RESULT result = nextTable.CreateImage(device, pCreateInfo, pImage);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600593 printf("xglCreateImage(device = %p, pCreateInfo = %p, pImage = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pImage, string_XGL_RESULT(result));
594 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_image_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600595 return result;
596}
597
598XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglGetImageSubresourceInfo(XGL_IMAGE image, const XGL_IMAGE_SUBRESOURCE* pSubresource, XGL_SUBRESOURCE_INFO_TYPE infoType, XGL_SIZE* pDataSize, XGL_VOID* pData)
599{
600 XGL_RESULT result = nextTable.GetImageSubresourceInfo(image, pSubresource, infoType, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600601 printf("xglGetImageSubresourceInfo(image = %p, pSubresource = %p, infoType = %s, pDataSize = %i, pData = %p) = %s\n", (void*)image, (void*)pSubresource, string_XGL_SUBRESOURCE_INFO_TYPE(infoType), *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600602 return result;
603}
604
605XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateImageView(XGL_DEVICE device, const XGL_IMAGE_VIEW_CREATE_INFO* pCreateInfo, XGL_IMAGE_VIEW* pView)
606{
607 XGL_RESULT result = nextTable.CreateImageView(device, pCreateInfo, pView);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600608 printf("xglCreateImageView(device = %p, pCreateInfo = %p, pView = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pView, string_XGL_RESULT(result));
609 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_image_view_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600610 return result;
611}
612
613XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateColorAttachmentView(XGL_DEVICE device, const XGL_COLOR_ATTACHMENT_VIEW_CREATE_INFO* pCreateInfo, XGL_COLOR_ATTACHMENT_VIEW* pView)
614{
615 XGL_RESULT result = nextTable.CreateColorAttachmentView(device, pCreateInfo, pView);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600616 printf("xglCreateColorAttachmentView(device = %p, pCreateInfo = %p, pView = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pView, string_XGL_RESULT(result));
617 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_color_attachment_view_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600618 return result;
619}
620
621XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateDepthStencilView(XGL_DEVICE device, const XGL_DEPTH_STENCIL_VIEW_CREATE_INFO* pCreateInfo, XGL_DEPTH_STENCIL_VIEW* pView)
622{
623 XGL_RESULT result = nextTable.CreateDepthStencilView(device, pCreateInfo, pView);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600624 printf("xglCreateDepthStencilView(device = %p, pCreateInfo = %p, pView = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pView, string_XGL_RESULT(result));
625 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_depth_stencil_view_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600626 return result;
627}
628
629XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateShader(XGL_DEVICE device, const XGL_SHADER_CREATE_INFO* pCreateInfo, XGL_SHADER* pShader)
630{
631 XGL_RESULT result = nextTable.CreateShader(device, pCreateInfo, pShader);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600632 printf("xglCreateShader(device = %p, pCreateInfo = %p, pShader = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pShader, string_XGL_RESULT(result));
633 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_shader_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600634 return result;
635}
636
637XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateGraphicsPipeline(XGL_DEVICE device, const XGL_GRAPHICS_PIPELINE_CREATE_INFO* pCreateInfo, XGL_PIPELINE* pPipeline)
638{
639 XGL_RESULT result = nextTable.CreateGraphicsPipeline(device, pCreateInfo, pPipeline);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600640 printf("xglCreateGraphicsPipeline(device = %p, pCreateInfo = %p, pPipeline = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pPipeline, string_XGL_RESULT(result));
641 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_graphics_pipeline_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600642 return result;
643}
644
645XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateComputePipeline(XGL_DEVICE device, const XGL_COMPUTE_PIPELINE_CREATE_INFO* pCreateInfo, XGL_PIPELINE* pPipeline)
646{
647 XGL_RESULT result = nextTable.CreateComputePipeline(device, pCreateInfo, pPipeline);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600648 printf("xglCreateComputePipeline(device = %p, pCreateInfo = %p, pPipeline = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pPipeline, string_XGL_RESULT(result));
649 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_compute_pipeline_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600650 return result;
651}
652
653XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglStorePipeline(XGL_PIPELINE pipeline, XGL_SIZE* pDataSize, XGL_VOID* pData)
654{
655 XGL_RESULT result = nextTable.StorePipeline(pipeline, pDataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600656 printf("xglStorePipeline(pipeline = %p, pDataSize = %i, pData = %p) = %s\n", (void*)pipeline, *pDataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600657 return result;
658}
659
660XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglLoadPipeline(XGL_DEVICE device, XGL_SIZE dataSize, const XGL_VOID* pData, XGL_PIPELINE* pPipeline)
661{
662 XGL_RESULT result = nextTable.LoadPipeline(device, dataSize, pData, pPipeline);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600663 printf("xglLoadPipeline(device = %p, dataSize = %i, pData = %p, pPipeline = %p) = %s\n", (void*)device, dataSize, (void*)pData, (void*)pPipeline, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600664 return result;
665}
666
667XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreatePipelineDelta(XGL_DEVICE device, XGL_PIPELINE p1, XGL_PIPELINE p2, XGL_PIPELINE_DELTA* delta)
668{
669 XGL_RESULT result = nextTable.CreatePipelineDelta(device, p1, p2, delta);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600670 printf("xglCreatePipelineDelta(device = %p, p1 = %p, p2 = %p, delta = %p) = %s\n", (void*)device, (void*)p1, (void*)p2, (void*)*delta, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600671 return result;
672}
673
674XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateSampler(XGL_DEVICE device, const XGL_SAMPLER_CREATE_INFO* pCreateInfo, XGL_SAMPLER* pSampler)
675{
676 XGL_RESULT result = nextTable.CreateSampler(device, pCreateInfo, pSampler);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600677 printf("xglCreateSampler(device = %p, pCreateInfo = %p, pSampler = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pSampler, string_XGL_RESULT(result));
678 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_sampler_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600679 return result;
680}
681
682XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateDescriptorSet(XGL_DEVICE device, const XGL_DESCRIPTOR_SET_CREATE_INFO* pCreateInfo, XGL_DESCRIPTOR_SET* pDescriptorSet)
683{
684 XGL_RESULT result = nextTable.CreateDescriptorSet(device, pCreateInfo, pDescriptorSet);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600685 printf("xglCreateDescriptorSet(device = %p, pCreateInfo = %p, pDescriptorSet = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pDescriptorSet, string_XGL_RESULT(result));
686 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_descriptor_set_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600687 return result;
688}
689
690XGL_LAYER_EXPORT XGL_VOID XGLAPI xglBeginDescriptorSetUpdate(XGL_DESCRIPTOR_SET descriptorSet)
691{
692 nextTable.BeginDescriptorSetUpdate(descriptorSet);
693 printf("xglBeginDescriptorSetUpdate(descriptorSet = %p)\n", (void*)descriptorSet);
694}
695
696XGL_LAYER_EXPORT XGL_VOID XGLAPI xglEndDescriptorSetUpdate(XGL_DESCRIPTOR_SET descriptorSet)
697{
698 nextTable.EndDescriptorSetUpdate(descriptorSet);
699 printf("xglEndDescriptorSetUpdate(descriptorSet = %p)\n", (void*)descriptorSet);
700}
701
702XGL_LAYER_EXPORT XGL_VOID XGLAPI xglAttachSamplerDescriptors(XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT startSlot, XGL_UINT slotCount, const XGL_SAMPLER* pSamplers)
703{
704 nextTable.AttachSamplerDescriptors(descriptorSet, startSlot, slotCount, pSamplers);
705 printf("xglAttachSamplerDescriptors(descriptorSet = %p, startSlot = %i, slotCount = %i, pSamplers = %p)\n", (void*)descriptorSet, startSlot, slotCount, (void*)pSamplers);
706}
707
708XGL_LAYER_EXPORT XGL_VOID XGLAPI xglAttachImageViewDescriptors(XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT startSlot, XGL_UINT slotCount, const XGL_IMAGE_VIEW_ATTACH_INFO* pImageViews)
709{
710 nextTable.AttachImageViewDescriptors(descriptorSet, startSlot, slotCount, pImageViews);
711 printf("xglAttachImageViewDescriptors(descriptorSet = %p, startSlot = %i, slotCount = %i, pImageViews = %p)\n", (void*)descriptorSet, startSlot, slotCount, (void*)pImageViews);
712}
713
714XGL_LAYER_EXPORT XGL_VOID XGLAPI xglAttachMemoryViewDescriptors(XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT startSlot, XGL_UINT slotCount, const XGL_MEMORY_VIEW_ATTACH_INFO* pMemViews)
715{
716 nextTable.AttachMemoryViewDescriptors(descriptorSet, startSlot, slotCount, pMemViews);
717 printf("xglAttachMemoryViewDescriptors(descriptorSet = %p, startSlot = %i, slotCount = %i, pMemViews = %p)\n", (void*)descriptorSet, startSlot, slotCount, (void*)pMemViews);
718}
719
720XGL_LAYER_EXPORT XGL_VOID XGLAPI xglAttachNestedDescriptors(XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT startSlot, XGL_UINT slotCount, const XGL_DESCRIPTOR_SET_ATTACH_INFO* pNestedDescriptorSets)
721{
722 nextTable.AttachNestedDescriptors(descriptorSet, startSlot, slotCount, pNestedDescriptorSets);
723 printf("xglAttachNestedDescriptors(descriptorSet = %p, startSlot = %i, slotCount = %i, pNestedDescriptorSets = %p)\n", (void*)descriptorSet, startSlot, slotCount, (void*)pNestedDescriptorSets);
724}
725
726XGL_LAYER_EXPORT XGL_VOID XGLAPI xglClearDescriptorSetSlots(XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT startSlot, XGL_UINT slotCount)
727{
728 nextTable.ClearDescriptorSetSlots(descriptorSet, startSlot, slotCount);
729 printf("xglClearDescriptorSetSlots(descriptorSet = %p, startSlot = %i, slotCount = %i)\n", (void*)descriptorSet, startSlot, slotCount);
730}
731
732XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateViewportState(XGL_DEVICE device, const XGL_VIEWPORT_STATE_CREATE_INFO* pCreateInfo, XGL_VIEWPORT_STATE_OBJECT* pState)
733{
734 XGL_RESULT result = nextTable.CreateViewportState(device, pCreateInfo, pState);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600735 printf("xglCreateViewportState(device = %p, pCreateInfo = %p, pState = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pState, string_XGL_RESULT(result));
736 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_viewport_state_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600737 return result;
738}
739
740XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateRasterState(XGL_DEVICE device, const XGL_RASTER_STATE_CREATE_INFO* pCreateInfo, XGL_RASTER_STATE_OBJECT* pState)
741{
742 XGL_RESULT result = nextTable.CreateRasterState(device, pCreateInfo, pState);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600743 printf("xglCreateRasterState(device = %p, pCreateInfo = %p, pState = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pState, string_XGL_RESULT(result));
744 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_raster_state_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600745 return result;
746}
747
748XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateMsaaState(XGL_DEVICE device, const XGL_MSAA_STATE_CREATE_INFO* pCreateInfo, XGL_MSAA_STATE_OBJECT* pState)
749{
750 XGL_RESULT result = nextTable.CreateMsaaState(device, pCreateInfo, pState);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600751 printf("xglCreateMsaaState(device = %p, pCreateInfo = %p, pState = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pState, string_XGL_RESULT(result));
752 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_msaa_state_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600753 return result;
754}
755
756XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateColorBlendState(XGL_DEVICE device, const XGL_COLOR_BLEND_STATE_CREATE_INFO* pCreateInfo, XGL_COLOR_BLEND_STATE_OBJECT* pState)
757{
758 XGL_RESULT result = nextTable.CreateColorBlendState(device, pCreateInfo, pState);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600759 printf("xglCreateColorBlendState(device = %p, pCreateInfo = %p, pState = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pState, string_XGL_RESULT(result));
760 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_color_blend_state_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600761 return result;
762}
763
764XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateDepthStencilState(XGL_DEVICE device, const XGL_DEPTH_STENCIL_STATE_CREATE_INFO* pCreateInfo, XGL_DEPTH_STENCIL_STATE_OBJECT* pState)
765{
766 XGL_RESULT result = nextTable.CreateDepthStencilState(device, pCreateInfo, pState);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600767 printf("xglCreateDepthStencilState(device = %p, pCreateInfo = %p, pState = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pState, string_XGL_RESULT(result));
768 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_depth_stencil_state_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600769 return result;
770}
771
772XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglCreateCommandBuffer(XGL_DEVICE device, const XGL_CMD_BUFFER_CREATE_INFO* pCreateInfo, XGL_CMD_BUFFER* pCmdBuffer)
773{
774 XGL_RESULT result = nextTable.CreateCommandBuffer(device, pCreateInfo, pCmdBuffer);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600775 printf("xglCreateCommandBuffer(device = %p, pCreateInfo = %p, pCmdBuffer = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)*pCmdBuffer, string_XGL_RESULT(result));
776 printf(" pCreateInfo (%p)\n%s\n", (void*)pCreateInfo, xgl_print_xgl_cmd_buffer_create_info(pCreateInfo, " "));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600777 return result;
778}
779
780XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglBeginCommandBuffer(XGL_CMD_BUFFER cmdBuffer, XGL_FLAGS flags)
781{
782 XGL_RESULT result = nextTable.BeginCommandBuffer(cmdBuffer, flags);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600783 printf("xglBeginCommandBuffer(cmdBuffer = %p, flags = %i) = %s\n", (void*)cmdBuffer, flags, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600784 return result;
785}
786
787XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglEndCommandBuffer(XGL_CMD_BUFFER cmdBuffer)
788{
789 XGL_RESULT result = nextTable.EndCommandBuffer(cmdBuffer);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600790 printf("xglEndCommandBuffer(cmdBuffer = %p) = %s\n", (void*)cmdBuffer, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600791 return result;
792}
793
794XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglResetCommandBuffer(XGL_CMD_BUFFER cmdBuffer)
795{
796 XGL_RESULT result = nextTable.ResetCommandBuffer(cmdBuffer);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600797 printf("xglResetCommandBuffer(cmdBuffer = %p) = %s\n", (void*)cmdBuffer, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600798 return result;
799}
800
801XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindPipeline(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_PIPELINE pipeline)
802{
803 nextTable.CmdBindPipeline(cmdBuffer, pipelineBindPoint, pipeline);
804 printf("xglCmdBindPipeline(cmdBuffer = %p, pipelineBindPoint = %i, pipeline = %p)\n", (void*)cmdBuffer, pipelineBindPoint, (void*)pipeline);
805}
806
807XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindPipelineDelta(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_PIPELINE_DELTA delta)
808{
809 nextTable.CmdBindPipelineDelta(cmdBuffer, pipelineBindPoint, delta);
810 printf("xglCmdBindPipelineDelta(cmdBuffer = %p, pipelineBindPoint = %i, delta = %p)\n", (void*)cmdBuffer, pipelineBindPoint, (void*)delta);
811}
812
813XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindStateObject(XGL_CMD_BUFFER cmdBuffer, XGL_STATE_BIND_POINT stateBindPoint, XGL_STATE_OBJECT state)
814{
815 nextTable.CmdBindStateObject(cmdBuffer, stateBindPoint, state);
816 printf("xglCmdBindStateObject(cmdBuffer = %p, stateBindPoint = %i, state = %p)\n", (void*)cmdBuffer, stateBindPoint, (void*)state);
817}
818
819XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindDescriptorSet(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_UINT index, XGL_DESCRIPTOR_SET descriptorSet, XGL_UINT slotOffset)
820{
821 nextTable.CmdBindDescriptorSet(cmdBuffer, pipelineBindPoint, index, descriptorSet, slotOffset);
822 printf("xglCmdBindDescriptorSet(cmdBuffer = %p, pipelineBindPoint = %i, index = %i, descriptorSet = %p, slotOffset = %i)\n", (void*)cmdBuffer, pipelineBindPoint, index, (void*)descriptorSet, slotOffset);
823}
824
825XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindDynamicMemoryView(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, const XGL_MEMORY_VIEW_ATTACH_INFO* pMemView)
826{
827 nextTable.CmdBindDynamicMemoryView(cmdBuffer, pipelineBindPoint, pMemView);
828 printf("xglCmdBindDynamicMemoryView(cmdBuffer = %p, pipelineBindPoint = %i, pMemView = %p)\n", (void*)cmdBuffer, pipelineBindPoint, (void*)pMemView);
829}
830
831XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindIndexData(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset, XGL_INDEX_TYPE indexType)
832{
833 nextTable.CmdBindIndexData(cmdBuffer, mem, offset, indexType);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600834 printf("xglCmdBindIndexData(cmdBuffer = %p, mem = %p, offset = %i, indexType = %s)\n", (void*)cmdBuffer, (void*)mem, offset, string_XGL_INDEX_TYPE(indexType));
Tobin Ehlis817736c2014-10-21 10:47:45 -0600835}
836
837XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBindAttachments(XGL_CMD_BUFFER cmdBuffer, XGL_UINT colorAttachmentCount, const XGL_COLOR_ATTACHMENT_BIND_INFO* pColorAttachments, const XGL_DEPTH_STENCIL_BIND_INFO* pDepthStencilAttachment)
838{
839 nextTable.CmdBindAttachments(cmdBuffer, colorAttachmentCount, pColorAttachments, pDepthStencilAttachment);
840 printf("xglCmdBindAttachments(cmdBuffer = %p, colorAttachmentCount = %i, pColorAttachments = %p, pDepthStencilAttachment = %p)\n", (void*)cmdBuffer, colorAttachmentCount, (void*)pColorAttachments, (void*)pDepthStencilAttachment);
841}
842
843XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdPrepareMemoryRegions(XGL_CMD_BUFFER cmdBuffer, XGL_UINT transitionCount, const XGL_MEMORY_STATE_TRANSITION* pStateTransitions)
844{
845 nextTable.CmdPrepareMemoryRegions(cmdBuffer, transitionCount, pStateTransitions);
846 printf("xglCmdPrepareMemoryRegions(cmdBuffer = %p, transitionCount = %i, pStateTransitions = %p)\n", (void*)cmdBuffer, transitionCount, (void*)pStateTransitions);
847}
848
849XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdPrepareImages(XGL_CMD_BUFFER cmdBuffer, XGL_UINT transitionCount, const XGL_IMAGE_STATE_TRANSITION* pStateTransitions)
850{
851 nextTable.CmdPrepareImages(cmdBuffer, transitionCount, pStateTransitions);
852 printf("xglCmdPrepareImages(cmdBuffer = %p, transitionCount = %i, pStateTransitions = %p)\n", (void*)cmdBuffer, transitionCount, (void*)pStateTransitions);
853}
854
855XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDraw(XGL_CMD_BUFFER cmdBuffer, XGL_UINT firstVertex, XGL_UINT vertexCount, XGL_UINT firstInstance, XGL_UINT instanceCount)
856{
857 nextTable.CmdDraw(cmdBuffer, firstVertex, vertexCount, firstInstance, instanceCount);
858 printf("xglCmdDraw(cmdBuffer = %p, firstVertex = %i, vertexCount = %i, firstInstance = %i, instanceCount = %i)\n", (void*)cmdBuffer, firstVertex, vertexCount, firstInstance, instanceCount);
859}
860
861XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDrawIndexed(XGL_CMD_BUFFER cmdBuffer, XGL_UINT firstIndex, XGL_UINT indexCount, XGL_INT vertexOffset, XGL_UINT firstInstance, XGL_UINT instanceCount)
862{
863 nextTable.CmdDrawIndexed(cmdBuffer, firstIndex, indexCount, vertexOffset, firstInstance, instanceCount);
864 printf("xglCmdDrawIndexed(cmdBuffer = %p, firstIndex = %i, indexCount = %i, vertexOffset = %i, firstInstance = %i, instanceCount = %i)\n", (void*)cmdBuffer, firstIndex, indexCount, vertexOffset, firstInstance, instanceCount);
865}
866
867XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDrawIndirect(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset, XGL_UINT32 count, XGL_UINT32 stride)
868{
869 nextTable.CmdDrawIndirect(cmdBuffer, mem, offset, count, stride);
870 printf("xglCmdDrawIndirect(cmdBuffer = %p, mem = %p, offset = %i, count = %i, stride = %i)\n", (void*)cmdBuffer, (void*)mem, offset, count, stride);
871}
872
873XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDrawIndexedIndirect(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset, XGL_UINT32 count, XGL_UINT32 stride)
874{
875 nextTable.CmdDrawIndexedIndirect(cmdBuffer, mem, offset, count, stride);
876 printf("xglCmdDrawIndexedIndirect(cmdBuffer = %p, mem = %p, offset = %i, count = %i, stride = %i)\n", (void*)cmdBuffer, (void*)mem, offset, count, stride);
877}
878
879XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDispatch(XGL_CMD_BUFFER cmdBuffer, XGL_UINT x, XGL_UINT y, XGL_UINT z)
880{
881 nextTable.CmdDispatch(cmdBuffer, x, y, z);
882 printf("xglCmdDispatch(cmdBuffer = %p, x = %i, y = %i, z = %i)\n", (void*)cmdBuffer, x, y, z);
883}
884
885XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDispatchIndirect(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY mem, XGL_GPU_SIZE offset)
886{
887 nextTable.CmdDispatchIndirect(cmdBuffer, mem, offset);
888 printf("xglCmdDispatchIndirect(cmdBuffer = %p, mem = %p, offset = %i)\n", (void*)cmdBuffer, (void*)mem, offset);
889}
890
891XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdCopyMemory(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY srcMem, XGL_GPU_MEMORY destMem, XGL_UINT regionCount, const XGL_MEMORY_COPY* pRegions)
892{
893 nextTable.CmdCopyMemory(cmdBuffer, srcMem, destMem, regionCount, pRegions);
894 printf("xglCmdCopyMemory(cmdBuffer = %p, srcMem = %p, destMem = %p, regionCount = %i, pRegions = %p)\n", (void*)cmdBuffer, (void*)srcMem, (void*)destMem, regionCount, (void*)pRegions);
895}
896
897XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdCopyImage(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE srcImage, XGL_IMAGE destImage, XGL_UINT regionCount, const XGL_IMAGE_COPY* pRegions)
898{
899 nextTable.CmdCopyImage(cmdBuffer, srcImage, destImage, regionCount, pRegions);
900 printf("xglCmdCopyImage(cmdBuffer = %p, srcImage = %p, destImage = %p, regionCount = %i, pRegions = %p)\n", (void*)cmdBuffer, (void*)srcImage, (void*)destImage, regionCount, (void*)pRegions);
901}
902
903XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdCopyMemoryToImage(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY srcMem, XGL_IMAGE destImage, XGL_UINT regionCount, const XGL_MEMORY_IMAGE_COPY* pRegions)
904{
905 nextTable.CmdCopyMemoryToImage(cmdBuffer, srcMem, destImage, regionCount, pRegions);
906 printf("xglCmdCopyMemoryToImage(cmdBuffer = %p, srcMem = %p, destImage = %p, regionCount = %i, pRegions = %p)\n", (void*)cmdBuffer, (void*)srcMem, (void*)destImage, regionCount, (void*)pRegions);
907}
908
909XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdCopyImageToMemory(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE srcImage, XGL_GPU_MEMORY destMem, XGL_UINT regionCount, const XGL_MEMORY_IMAGE_COPY* pRegions)
910{
911 nextTable.CmdCopyImageToMemory(cmdBuffer, srcImage, destMem, regionCount, pRegions);
912 printf("xglCmdCopyImageToMemory(cmdBuffer = %p, srcImage = %p, destMem = %p, regionCount = %i, pRegions = %p)\n", (void*)cmdBuffer, (void*)srcImage, (void*)destMem, regionCount, (void*)pRegions);
913}
914
915XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdCloneImageData(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE srcImage, XGL_IMAGE_STATE srcImageState, XGL_IMAGE destImage, XGL_IMAGE_STATE destImageState)
916{
917 nextTable.CmdCloneImageData(cmdBuffer, srcImage, srcImageState, destImage, destImageState);
918 printf("xglCmdCloneImageData(cmdBuffer = %p, srcImage = %p, srcImageState = %p, destImage = %p, destImageState = %p)\n", (void*)cmdBuffer, (void*)srcImage, (void*)srcImageState, (void*)destImage, (void*)destImageState);
919}
920
921XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdUpdateMemory(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY destMem, XGL_GPU_SIZE destOffset, XGL_GPU_SIZE dataSize, const XGL_UINT32* pData)
922{
923 nextTable.CmdUpdateMemory(cmdBuffer, destMem, destOffset, dataSize, pData);
924 printf("xglCmdUpdateMemory(cmdBuffer = %p, destMem = %p, destOffset = %i, dataSize = %i, pData = %i)\n", (void*)cmdBuffer, (void*)destMem, destOffset, dataSize, *pData);
925}
926
927XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdFillMemory(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY destMem, XGL_GPU_SIZE destOffset, XGL_GPU_SIZE fillSize, XGL_UINT32 data)
928{
929 nextTable.CmdFillMemory(cmdBuffer, destMem, destOffset, fillSize, data);
930 printf("xglCmdFillMemory(cmdBuffer = %p, destMem = %p, destOffset = %i, fillSize = %i, data = %i)\n", (void*)cmdBuffer, (void*)destMem, destOffset, fillSize, data);
931}
932
933XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdClearColorImage(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, const XGL_FLOAT color[4], XGL_UINT rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
934{
935 nextTable.CmdClearColorImage(cmdBuffer, image, color, rangeCount, pRanges);
936 printf("xglCmdClearColorImage(cmdBuffer = %p, image = %p, color = [%f, %f, %f, %f], rangeCount = %i, pRanges = %p)\n", (void*)cmdBuffer, (void*)image, color[0], color[1], color[2], color[3], rangeCount, (void*)pRanges);
937}
938
939XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdClearColorImageRaw(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, const XGL_UINT32 color[4], XGL_UINT rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
940{
941 nextTable.CmdClearColorImageRaw(cmdBuffer, image, color, rangeCount, pRanges);
942 printf("xglCmdClearColorImageRaw(cmdBuffer = %p, image = %p, color = [%i, %i, %i, %i], rangeCount = %i, pRanges = %p)\n", (void*)cmdBuffer, (void*)image, color[0], color[1], color[2], color[3], rangeCount, (void*)pRanges);
943}
944
945XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdClearDepthStencil(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE image, XGL_FLOAT depth, XGL_UINT32 stencil, XGL_UINT rangeCount, const XGL_IMAGE_SUBRESOURCE_RANGE* pRanges)
946{
947 nextTable.CmdClearDepthStencil(cmdBuffer, image, depth, stencil, rangeCount, pRanges);
948 printf("xglCmdClearDepthStencil(cmdBuffer = %p, image = %p, depth = %f, stencil = %i, rangeCount = %i, pRanges = %p)\n", (void*)cmdBuffer, (void*)image, depth, stencil, rangeCount, (void*)pRanges);
949}
950
951XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdResolveImage(XGL_CMD_BUFFER cmdBuffer, XGL_IMAGE srcImage, XGL_IMAGE destImage, XGL_UINT rectCount, const XGL_IMAGE_RESOLVE* pRects)
952{
953 nextTable.CmdResolveImage(cmdBuffer, srcImage, destImage, rectCount, pRects);
954 printf("xglCmdResolveImage(cmdBuffer = %p, srcImage = %p, destImage = %p, rectCount = %i, pRects = %p)\n", (void*)cmdBuffer, (void*)srcImage, (void*)destImage, rectCount, (void*)pRects);
955}
956
957XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdSetEvent(XGL_CMD_BUFFER cmdBuffer, XGL_EVENT event)
958{
959 nextTable.CmdSetEvent(cmdBuffer, event);
960 printf("xglCmdSetEvent(cmdBuffer = %p, event = %p)\n", (void*)cmdBuffer, (void*)event);
961}
962
963XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdResetEvent(XGL_CMD_BUFFER cmdBuffer, XGL_EVENT event)
964{
965 nextTable.CmdResetEvent(cmdBuffer, event);
966 printf("xglCmdResetEvent(cmdBuffer = %p, event = %p)\n", (void*)cmdBuffer, (void*)event);
967}
968
969XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdMemoryAtomic(XGL_CMD_BUFFER cmdBuffer, XGL_GPU_MEMORY destMem, XGL_GPU_SIZE destOffset, XGL_UINT64 srcData, XGL_ATOMIC_OP atomicOp)
970{
971 nextTable.CmdMemoryAtomic(cmdBuffer, destMem, destOffset, srcData, atomicOp);
972 printf("xglCmdMemoryAtomic(cmdBuffer = %p, destMem = %p, destOffset = %i, srcData = %lu, atomicOp = %p)\n", (void*)cmdBuffer, (void*)destMem, destOffset, srcData, (void*)atomicOp);
973}
974
975XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdBeginQuery(XGL_CMD_BUFFER cmdBuffer, XGL_QUERY_POOL queryPool, XGL_UINT slot, XGL_FLAGS flags)
976{
977 nextTable.CmdBeginQuery(cmdBuffer, queryPool, slot, flags);
978 printf("xglCmdBeginQuery(cmdBuffer = %p, queryPool = %p, slot = %i, flags = %i)\n", (void*)cmdBuffer, (void*)queryPool, slot, flags);
979}
980
981XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdEndQuery(XGL_CMD_BUFFER cmdBuffer, XGL_QUERY_POOL queryPool, XGL_UINT slot)
982{
983 nextTable.CmdEndQuery(cmdBuffer, queryPool, slot);
984 printf("xglCmdEndQuery(cmdBuffer = %p, queryPool = %p, slot = %i)\n", (void*)cmdBuffer, (void*)queryPool, slot);
985}
986
987XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdResetQueryPool(XGL_CMD_BUFFER cmdBuffer, XGL_QUERY_POOL queryPool, XGL_UINT startQuery, XGL_UINT queryCount)
988{
989 nextTable.CmdResetQueryPool(cmdBuffer, queryPool, startQuery, queryCount);
990 printf("xglCmdResetQueryPool(cmdBuffer = %p, queryPool = %p, startQuery = %i, queryCount = %i)\n", (void*)cmdBuffer, (void*)queryPool, startQuery, queryCount);
991}
992
993XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdWriteTimestamp(XGL_CMD_BUFFER cmdBuffer, XGL_TIMESTAMP_TYPE timestampType, XGL_GPU_MEMORY destMem, XGL_GPU_SIZE destOffset)
994{
995 nextTable.CmdWriteTimestamp(cmdBuffer, timestampType, destMem, destOffset);
Tobin Ehlis92dbf802014-10-22 09:06:33 -0600996 printf("xglCmdWriteTimestamp(cmdBuffer = %p, timestampType = %s, destMem = %p, destOffset = %i)\n", (void*)cmdBuffer, string_XGL_TIMESTAMP_TYPE(timestampType), (void*)destMem, destOffset);
Tobin Ehlis817736c2014-10-21 10:47:45 -0600997}
998
999XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdInitAtomicCounters(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_UINT startCounter, XGL_UINT counterCount, const XGL_UINT32* pData)
1000{
1001 nextTable.CmdInitAtomicCounters(cmdBuffer, pipelineBindPoint, startCounter, counterCount, pData);
1002 printf("xglCmdInitAtomicCounters(cmdBuffer = %p, pipelineBindPoint = %i, startCounter = %i, counterCount = %i, pData = %i)\n", (void*)cmdBuffer, pipelineBindPoint, startCounter, counterCount, *pData);
1003}
1004
1005XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdLoadAtomicCounters(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_UINT startCounter, XGL_UINT counterCount, XGL_GPU_MEMORY srcMem, XGL_GPU_SIZE srcOffset)
1006{
1007 nextTable.CmdLoadAtomicCounters(cmdBuffer, pipelineBindPoint, startCounter, counterCount, srcMem, srcOffset);
1008 printf("xglCmdLoadAtomicCounters(cmdBuffer = %p, pipelineBindPoint = %i, startCounter = %i, counterCount = %i, srcMem = %p, srcOffset = %i)\n", (void*)cmdBuffer, pipelineBindPoint, startCounter, counterCount, (void*)srcMem, srcOffset);
1009}
1010
1011XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdSaveAtomicCounters(XGL_CMD_BUFFER cmdBuffer, XGL_PIPELINE_BIND_POINT pipelineBindPoint, XGL_UINT startCounter, XGL_UINT counterCount, XGL_GPU_MEMORY destMem, XGL_GPU_SIZE destOffset)
1012{
1013 nextTable.CmdSaveAtomicCounters(cmdBuffer, pipelineBindPoint, startCounter, counterCount, destMem, destOffset);
1014 printf("xglCmdSaveAtomicCounters(cmdBuffer = %p, pipelineBindPoint = %i, startCounter = %i, counterCount = %i, destMem = %p, destOffset = %i)\n", (void*)cmdBuffer, pipelineBindPoint, startCounter, counterCount, (void*)destMem, destOffset);
1015}
1016
1017XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgSetValidationLevel(XGL_DEVICE device, XGL_VALIDATION_LEVEL validationLevel)
1018{
1019 XGL_RESULT result = nextTable.DbgSetValidationLevel(device, validationLevel);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001020 printf("xglDbgSetValidationLevel(device = %p, validationLevel = %p) = %s\n", (void*)device, (void*)validationLevel, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001021 return result;
1022}
1023
1024XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgRegisterMsgCallback(XGL_DBG_MSG_CALLBACK_FUNCTION pfnMsgCallback, XGL_VOID* pUserData)
1025{
1026 XGL_RESULT result = nextTable.DbgRegisterMsgCallback(pfnMsgCallback, pUserData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001027 printf("xglDbgRegisterMsgCallback(pfnMsgCallback = %p, pUserData = %p) = %s\n", (void*)pfnMsgCallback, (void*)pUserData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001028 return result;
1029}
1030
1031XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgUnregisterMsgCallback(XGL_DBG_MSG_CALLBACK_FUNCTION pfnMsgCallback)
1032{
1033 XGL_RESULT result = nextTable.DbgUnregisterMsgCallback(pfnMsgCallback);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001034 printf("xglDbgUnregisterMsgCallback(pfnMsgCallback = %p) = %s\n", (void*)pfnMsgCallback, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001035 return result;
1036}
1037
1038XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgSetMessageFilter(XGL_DEVICE device, XGL_INT msgCode, XGL_DBG_MSG_FILTER filter)
1039{
1040 XGL_RESULT result = nextTable.DbgSetMessageFilter(device, msgCode, filter);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001041 printf("xglDbgSetMessageFilter(device = %p, msgCode = %i, filter = %p) = %s\n", (void*)device, msgCode, (void*)filter, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001042 return result;
1043}
1044
1045XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgSetObjectTag(XGL_BASE_OBJECT object, XGL_SIZE tagSize, const XGL_VOID* pTag)
1046{
1047 XGL_RESULT result = nextTable.DbgSetObjectTag(object, tagSize, pTag);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001048 printf("xglDbgSetObjectTag(object = %p, tagSize = %i, pTag = %p) = %s\n", (void*)object, tagSize, (void*)pTag, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001049 return result;
1050}
1051
1052XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgSetGlobalOption(XGL_DBG_GLOBAL_OPTION dbgOption, XGL_SIZE dataSize, const XGL_VOID* pData)
1053{
1054 XGL_RESULT result = nextTable.DbgSetGlobalOption(dbgOption, dataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001055 printf("xglDbgSetGlobalOption(dbgOption = %p, dataSize = %i, pData = %p) = %s\n", (void*)dbgOption, dataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001056 return result;
1057}
1058
1059XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglDbgSetDeviceOption(XGL_DEVICE device, XGL_DBG_DEVICE_OPTION dbgOption, XGL_SIZE dataSize, const XGL_VOID* pData)
1060{
1061 XGL_RESULT result = nextTable.DbgSetDeviceOption(device, dbgOption, dataSize, pData);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001062 printf("xglDbgSetDeviceOption(device = %p, dbgOption = %p, dataSize = %i, pData = %p) = %s\n", (void*)device, (void*)dbgOption, dataSize, (void*)pData, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001063 return result;
1064}
1065
1066XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDbgMarkerBegin(XGL_CMD_BUFFER cmdBuffer, const XGL_CHAR* pMarker)
1067{
1068 nextTable.CmdDbgMarkerBegin(cmdBuffer, pMarker);
1069 printf("xglCmdDbgMarkerBegin(cmdBuffer = %p, pMarker = %p)\n", (void*)cmdBuffer, (void*)pMarker);
1070}
1071
1072XGL_LAYER_EXPORT XGL_VOID XGLAPI xglCmdDbgMarkerEnd(XGL_CMD_BUFFER cmdBuffer)
1073{
1074 nextTable.CmdDbgMarkerEnd(cmdBuffer);
1075 printf("xglCmdDbgMarkerEnd(cmdBuffer = %p)\n", (void*)cmdBuffer);
1076}
1077
1078XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWsiX11AssociateConnection(XGL_PHYSICAL_GPU gpu, const XGL_WSI_X11_CONNECTION_INFO* pConnectionInfo)
1079{
1080 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
Tobin Ehlis817736c2014-10-21 10:47:45 -06001081 pCurObj = gpuw;
1082 pthread_once(&tabOnce, initLayerTable);
1083 XGL_RESULT result = nextTable.WsiX11AssociateConnection((XGL_PHYSICAL_GPU)gpuw->nextObject, pConnectionInfo);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001084 printf("xglWsiX11AssociateConnection(gpu = %p, pConnectionInfo = %p) = %s\n", (void*)gpu, (void*)pConnectionInfo, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001085 return result;
1086}
1087
1088XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWsiX11GetMSC(XGL_DEVICE device, xcb_randr_crtc_t crtc, XGL_UINT64* pMsc)
1089{
1090 XGL_RESULT result = nextTable.WsiX11GetMSC(device, crtc, pMsc);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001091 printf("xglWsiX11GetMSC(device = %p, crtc = %i, pMsc = %lu) = %s\n", (void*)device, crtc, *pMsc, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001092 return result;
1093}
1094
1095XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWsiX11CreatePresentableImage(XGL_DEVICE device, const XGL_WSI_X11_PRESENTABLE_IMAGE_CREATE_INFO* pCreateInfo, XGL_IMAGE* pImage, XGL_GPU_MEMORY* pMem)
1096{
1097 XGL_RESULT result = nextTable.WsiX11CreatePresentableImage(device, pCreateInfo, pImage, pMem);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001098 printf("xglWsiX11CreatePresentableImage(device = %p, pCreateInfo = %p, pImage = %p, pMem = %p) = %s\n", (void*)device, (void*)pCreateInfo, (void*)pImage, (void*)pMem, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001099 return result;
1100}
1101
1102XGL_LAYER_EXPORT XGL_RESULT XGLAPI xglWsiX11QueuePresent(XGL_QUEUE queue, const XGL_WSI_X11_PRESENT_INFO* pPresentInfo, XGL_FENCE fence)
1103{
1104 XGL_RESULT result = nextTable.WsiX11QueuePresent(queue, pPresentInfo, fence);
Tobin Ehlis92dbf802014-10-22 09:06:33 -06001105 printf("xglWsiX11QueuePresent(queue = %p, pPresentInfo = %p, fence = %p) = %s\n", (void*)queue, (void*)pPresentInfo, (void*)fence, string_XGL_RESULT(result));
Tobin Ehlis817736c2014-10-21 10:47:45 -06001106 return result;
1107}
1108
1109XGL_LAYER_EXPORT XGL_VOID* XGLAPI xglGetProcAddr(XGL_PHYSICAL_GPU gpu, const XGL_CHAR* funcName)
1110{
1111 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
1112 if (gpu == NULL)
1113 return NULL;
1114 pCurObj = gpuw;
1115 pthread_once(&tabOnce, initLayerTable);
1116
1117 if (!strncmp("xglGetProcAddr", (const char *) funcName, sizeof("xglGetProcAddr")))
1118 return xglGetProcAddr;
1119 else if (!strncmp("xglInitAndEnumerateGpus", (const char *) funcName, sizeof("xglInitAndEnumerateGpus")))
1120 return nextTable.InitAndEnumerateGpus;
1121 else if (!strncmp("xglGetGpuInfo", (const char *) funcName, sizeof("xglGetGpuInfo")))
1122 return xglGetGpuInfo;
1123 else if (!strncmp("xglCreateDevice", (const char *) funcName, sizeof("xglCreateDevice")))
1124 return xglCreateDevice;
1125 else if (!strncmp("xglDestroyDevice", (const char *) funcName, sizeof("xglDestroyDevice")))
1126 return xglDestroyDevice;
1127 else if (!strncmp("xglGetExtensionSupport", (const char *) funcName, sizeof("xglGetExtensionSupport")))
1128 return xglGetExtensionSupport;
1129 else if (!strncmp("xglEnumerateLayers", (const char *) funcName, sizeof("xglEnumerateLayers")))
1130 return xglEnumerateLayers;
1131 else if (!strncmp("xglGetDeviceQueue", (const char *) funcName, sizeof("xglGetDeviceQueue")))
1132 return xglGetDeviceQueue;
1133 else if (!strncmp("xglQueueSubmit", (const char *) funcName, sizeof("xglQueueSubmit")))
1134 return xglQueueSubmit;
1135 else if (!strncmp("xglQueueSetGlobalMemReferences", (const char *) funcName, sizeof("xglQueueSetGlobalMemReferences")))
1136 return xglQueueSetGlobalMemReferences;
1137 else if (!strncmp("xglQueueWaitIdle", (const char *) funcName, sizeof("xglQueueWaitIdle")))
1138 return xglQueueWaitIdle;
1139 else if (!strncmp("xglDeviceWaitIdle", (const char *) funcName, sizeof("xglDeviceWaitIdle")))
1140 return xglDeviceWaitIdle;
1141 else if (!strncmp("xglGetMemoryHeapCount", (const char *) funcName, sizeof("xglGetMemoryHeapCount")))
1142 return xglGetMemoryHeapCount;
1143 else if (!strncmp("xglGetMemoryHeapInfo", (const char *) funcName, sizeof("xglGetMemoryHeapInfo")))
1144 return xglGetMemoryHeapInfo;
1145 else if (!strncmp("xglAllocMemory", (const char *) funcName, sizeof("xglAllocMemory")))
1146 return xglAllocMemory;
1147 else if (!strncmp("xglFreeMemory", (const char *) funcName, sizeof("xglFreeMemory")))
1148 return xglFreeMemory;
1149 else if (!strncmp("xglSetMemoryPriority", (const char *) funcName, sizeof("xglSetMemoryPriority")))
1150 return xglSetMemoryPriority;
1151 else if (!strncmp("xglMapMemory", (const char *) funcName, sizeof("xglMapMemory")))
1152 return xglMapMemory;
1153 else if (!strncmp("xglUnmapMemory", (const char *) funcName, sizeof("xglUnmapMemory")))
1154 return xglUnmapMemory;
1155 else if (!strncmp("xglPinSystemMemory", (const char *) funcName, sizeof("xglPinSystemMemory")))
1156 return xglPinSystemMemory;
1157 else if (!strncmp("xglRemapVirtualMemoryPages", (const char *) funcName, sizeof("xglRemapVirtualMemoryPages")))
1158 return xglRemapVirtualMemoryPages;
1159 else if (!strncmp("xglGetMultiGpuCompatibility", (const char *) funcName, sizeof("xglGetMultiGpuCompatibility")))
1160 return xglGetMultiGpuCompatibility;
1161 else if (!strncmp("xglOpenSharedMemory", (const char *) funcName, sizeof("xglOpenSharedMemory")))
1162 return xglOpenSharedMemory;
1163 else if (!strncmp("xglOpenSharedQueueSemaphore", (const char *) funcName, sizeof("xglOpenSharedQueueSemaphore")))
1164 return xglOpenSharedQueueSemaphore;
1165 else if (!strncmp("xglOpenPeerMemory", (const char *) funcName, sizeof("xglOpenPeerMemory")))
1166 return xglOpenPeerMemory;
1167 else if (!strncmp("xglOpenPeerImage", (const char *) funcName, sizeof("xglOpenPeerImage")))
1168 return xglOpenPeerImage;
1169 else if (!strncmp("xglDestroyObject", (const char *) funcName, sizeof("xglDestroyObject")))
1170 return xglDestroyObject;
1171 else if (!strncmp("xglGetObjectInfo", (const char *) funcName, sizeof("xglGetObjectInfo")))
1172 return xglGetObjectInfo;
1173 else if (!strncmp("xglBindObjectMemory", (const char *) funcName, sizeof("xglBindObjectMemory")))
1174 return xglBindObjectMemory;
1175 else if (!strncmp("xglCreateFence", (const char *) funcName, sizeof("xglCreateFence")))
1176 return xglCreateFence;
1177 else if (!strncmp("xglGetFenceStatus", (const char *) funcName, sizeof("xglGetFenceStatus")))
1178 return xglGetFenceStatus;
1179 else if (!strncmp("xglWaitForFences", (const char *) funcName, sizeof("xglWaitForFences")))
1180 return xglWaitForFences;
1181 else if (!strncmp("xglCreateQueueSemaphore", (const char *) funcName, sizeof("xglCreateQueueSemaphore")))
1182 return xglCreateQueueSemaphore;
1183 else if (!strncmp("xglSignalQueueSemaphore", (const char *) funcName, sizeof("xglSignalQueueSemaphore")))
1184 return xglSignalQueueSemaphore;
1185 else if (!strncmp("xglWaitQueueSemaphore", (const char *) funcName, sizeof("xglWaitQueueSemaphore")))
1186 return xglWaitQueueSemaphore;
1187 else if (!strncmp("xglCreateEvent", (const char *) funcName, sizeof("xglCreateEvent")))
1188 return xglCreateEvent;
1189 else if (!strncmp("xglGetEventStatus", (const char *) funcName, sizeof("xglGetEventStatus")))
1190 return xglGetEventStatus;
1191 else if (!strncmp("xglSetEvent", (const char *) funcName, sizeof("xglSetEvent")))
1192 return xglSetEvent;
1193 else if (!strncmp("xglResetEvent", (const char *) funcName, sizeof("xglResetEvent")))
1194 return xglResetEvent;
1195 else if (!strncmp("xglCreateQueryPool", (const char *) funcName, sizeof("xglCreateQueryPool")))
1196 return xglCreateQueryPool;
1197 else if (!strncmp("xglGetQueryPoolResults", (const char *) funcName, sizeof("xglGetQueryPoolResults")))
1198 return xglGetQueryPoolResults;
1199 else if (!strncmp("xglGetFormatInfo", (const char *) funcName, sizeof("xglGetFormatInfo")))
1200 return xglGetFormatInfo;
1201 else if (!strncmp("xglCreateImage", (const char *) funcName, sizeof("xglCreateImage")))
1202 return xglCreateImage;
1203 else if (!strncmp("xglGetImageSubresourceInfo", (const char *) funcName, sizeof("xglGetImageSubresourceInfo")))
1204 return xglGetImageSubresourceInfo;
1205 else if (!strncmp("xglCreateImageView", (const char *) funcName, sizeof("xglCreateImageView")))
1206 return xglCreateImageView;
1207 else if (!strncmp("xglCreateColorAttachmentView", (const char *) funcName, sizeof("xglCreateColorAttachmentView")))
1208 return xglCreateColorAttachmentView;
1209 else if (!strncmp("xglCreateDepthStencilView", (const char *) funcName, sizeof("xglCreateDepthStencilView")))
1210 return xglCreateDepthStencilView;
1211 else if (!strncmp("xglCreateShader", (const char *) funcName, sizeof("xglCreateShader")))
1212 return xglCreateShader;
1213 else if (!strncmp("xglCreateGraphicsPipeline", (const char *) funcName, sizeof("xglCreateGraphicsPipeline")))
1214 return xglCreateGraphicsPipeline;
1215 else if (!strncmp("xglCreateComputePipeline", (const char *) funcName, sizeof("xglCreateComputePipeline")))
1216 return xglCreateComputePipeline;
1217 else if (!strncmp("xglStorePipeline", (const char *) funcName, sizeof("xglStorePipeline")))
1218 return xglStorePipeline;
1219 else if (!strncmp("xglLoadPipeline", (const char *) funcName, sizeof("xglLoadPipeline")))
1220 return xglLoadPipeline;
1221 else if (!strncmp("xglCreatePipelineDelta", (const char *) funcName, sizeof("xglCreatePipelineDelta")))
1222 return xglCreatePipelineDelta;
1223 else if (!strncmp("xglCreateSampler", (const char *) funcName, sizeof("xglCreateSampler")))
1224 return xglCreateSampler;
1225 else if (!strncmp("xglCreateDescriptorSet", (const char *) funcName, sizeof("xglCreateDescriptorSet")))
1226 return xglCreateDescriptorSet;
1227 else if (!strncmp("xglBeginDescriptorSetUpdate", (const char *) funcName, sizeof("xglBeginDescriptorSetUpdate")))
1228 return xglBeginDescriptorSetUpdate;
1229 else if (!strncmp("xglEndDescriptorSetUpdate", (const char *) funcName, sizeof("xglEndDescriptorSetUpdate")))
1230 return xglEndDescriptorSetUpdate;
1231 else if (!strncmp("xglAttachSamplerDescriptors", (const char *) funcName, sizeof("xglAttachSamplerDescriptors")))
1232 return xglAttachSamplerDescriptors;
1233 else if (!strncmp("xglAttachImageViewDescriptors", (const char *) funcName, sizeof("xglAttachImageViewDescriptors")))
1234 return xglAttachImageViewDescriptors;
1235 else if (!strncmp("xglAttachMemoryViewDescriptors", (const char *) funcName, sizeof("xglAttachMemoryViewDescriptors")))
1236 return xglAttachMemoryViewDescriptors;
1237 else if (!strncmp("xglAttachNestedDescriptors", (const char *) funcName, sizeof("xglAttachNestedDescriptors")))
1238 return xglAttachNestedDescriptors;
1239 else if (!strncmp("xglClearDescriptorSetSlots", (const char *) funcName, sizeof("xglClearDescriptorSetSlots")))
1240 return xglClearDescriptorSetSlots;
1241 else if (!strncmp("xglCreateViewportState", (const char *) funcName, sizeof("xglCreateViewportState")))
1242 return xglCreateViewportState;
1243 else if (!strncmp("xglCreateRasterState", (const char *) funcName, sizeof("xglCreateRasterState")))
1244 return xglCreateRasterState;
1245 else if (!strncmp("xglCreateMsaaState", (const char *) funcName, sizeof("xglCreateMsaaState")))
1246 return xglCreateMsaaState;
1247 else if (!strncmp("xglCreateColorBlendState", (const char *) funcName, sizeof("xglCreateColorBlendState")))
1248 return xglCreateColorBlendState;
1249 else if (!strncmp("xglCreateDepthStencilState", (const char *) funcName, sizeof("xglCreateDepthStencilState")))
1250 return xglCreateDepthStencilState;
1251 else if (!strncmp("xglCreateCommandBuffer", (const char *) funcName, sizeof("xglCreateCommandBuffer")))
1252 return xglCreateCommandBuffer;
1253 else if (!strncmp("xglBeginCommandBuffer", (const char *) funcName, sizeof("xglBeginCommandBuffer")))
1254 return xglBeginCommandBuffer;
1255 else if (!strncmp("xglEndCommandBuffer", (const char *) funcName, sizeof("xglEndCommandBuffer")))
1256 return xglEndCommandBuffer;
1257 else if (!strncmp("xglResetCommandBuffer", (const char *) funcName, sizeof("xglResetCommandBuffer")))
1258 return xglResetCommandBuffer;
1259 else if (!strncmp("xglCmdBindPipeline", (const char *) funcName, sizeof("xglCmdBindPipeline")))
1260 return xglCmdBindPipeline;
1261 else if (!strncmp("xglCmdBindPipelineDelta", (const char *) funcName, sizeof("xglCmdBindPipelineDelta")))
1262 return xglCmdBindPipelineDelta;
1263 else if (!strncmp("xglCmdBindStateObject", (const char *) funcName, sizeof("xglCmdBindStateObject")))
1264 return xglCmdBindStateObject;
1265 else if (!strncmp("xglCmdBindDescriptorSet", (const char *) funcName, sizeof("xglCmdBindDescriptorSet")))
1266 return xglCmdBindDescriptorSet;
1267 else if (!strncmp("xglCmdBindDynamicMemoryView", (const char *) funcName, sizeof("xglCmdBindDynamicMemoryView")))
1268 return xglCmdBindDynamicMemoryView;
1269 else if (!strncmp("xglCmdBindIndexData", (const char *) funcName, sizeof("xglCmdBindIndexData")))
1270 return xglCmdBindIndexData;
1271 else if (!strncmp("xglCmdBindAttachments", (const char *) funcName, sizeof("xglCmdBindAttachments")))
1272 return xglCmdBindAttachments;
1273 else if (!strncmp("xglCmdPrepareMemoryRegions", (const char *) funcName, sizeof("xglCmdPrepareMemoryRegions")))
1274 return xglCmdPrepareMemoryRegions;
1275 else if (!strncmp("xglCmdPrepareImages", (const char *) funcName, sizeof("xglCmdPrepareImages")))
1276 return xglCmdPrepareImages;
1277 else if (!strncmp("xglCmdDraw", (const char *) funcName, sizeof("xglCmdDraw")))
1278 return xglCmdDraw;
1279 else if (!strncmp("xglCmdDrawIndexed", (const char *) funcName, sizeof("xglCmdDrawIndexed")))
1280 return xglCmdDrawIndexed;
1281 else if (!strncmp("xglCmdDrawIndirect", (const char *) funcName, sizeof("xglCmdDrawIndirect")))
1282 return xglCmdDrawIndirect;
1283 else if (!strncmp("xglCmdDrawIndexedIndirect", (const char *) funcName, sizeof("xglCmdDrawIndexedIndirect")))
1284 return xglCmdDrawIndexedIndirect;
1285 else if (!strncmp("xglCmdDispatch", (const char *) funcName, sizeof("xglCmdDispatch")))
1286 return xglCmdDispatch;
1287 else if (!strncmp("xglCmdDispatchIndirect", (const char *) funcName, sizeof("xglCmdDispatchIndirect")))
1288 return xglCmdDispatchIndirect;
1289 else if (!strncmp("xglCmdCopyMemory", (const char *) funcName, sizeof("xglCmdCopyMemory")))
1290 return xglCmdCopyMemory;
1291 else if (!strncmp("xglCmdCopyImage", (const char *) funcName, sizeof("xglCmdCopyImage")))
1292 return xglCmdCopyImage;
1293 else if (!strncmp("xglCmdCopyMemoryToImage", (const char *) funcName, sizeof("xglCmdCopyMemoryToImage")))
1294 return xglCmdCopyMemoryToImage;
1295 else if (!strncmp("xglCmdCopyImageToMemory", (const char *) funcName, sizeof("xglCmdCopyImageToMemory")))
1296 return xglCmdCopyImageToMemory;
1297 else if (!strncmp("xglCmdCloneImageData", (const char *) funcName, sizeof("xglCmdCloneImageData")))
1298 return xglCmdCloneImageData;
1299 else if (!strncmp("xglCmdUpdateMemory", (const char *) funcName, sizeof("xglCmdUpdateMemory")))
1300 return xglCmdUpdateMemory;
1301 else if (!strncmp("xglCmdFillMemory", (const char *) funcName, sizeof("xglCmdFillMemory")))
1302 return xglCmdFillMemory;
1303 else if (!strncmp("xglCmdClearColorImage", (const char *) funcName, sizeof("xglCmdClearColorImage")))
1304 return xglCmdClearColorImage;
1305 else if (!strncmp("xglCmdClearColorImageRaw", (const char *) funcName, sizeof("xglCmdClearColorImageRaw")))
1306 return xglCmdClearColorImageRaw;
1307 else if (!strncmp("xglCmdClearDepthStencil", (const char *) funcName, sizeof("xglCmdClearDepthStencil")))
1308 return xglCmdClearDepthStencil;
1309 else if (!strncmp("xglCmdResolveImage", (const char *) funcName, sizeof("xglCmdResolveImage")))
1310 return xglCmdResolveImage;
1311 else if (!strncmp("xglCmdSetEvent", (const char *) funcName, sizeof("xglCmdSetEvent")))
1312 return xglCmdSetEvent;
1313 else if (!strncmp("xglCmdResetEvent", (const char *) funcName, sizeof("xglCmdResetEvent")))
1314 return xglCmdResetEvent;
1315 else if (!strncmp("xglCmdMemoryAtomic", (const char *) funcName, sizeof("xglCmdMemoryAtomic")))
1316 return xglCmdMemoryAtomic;
1317 else if (!strncmp("xglCmdBeginQuery", (const char *) funcName, sizeof("xglCmdBeginQuery")))
1318 return xglCmdBeginQuery;
1319 else if (!strncmp("xglCmdEndQuery", (const char *) funcName, sizeof("xglCmdEndQuery")))
1320 return xglCmdEndQuery;
1321 else if (!strncmp("xglCmdResetQueryPool", (const char *) funcName, sizeof("xglCmdResetQueryPool")))
1322 return xglCmdResetQueryPool;
1323 else if (!strncmp("xglCmdWriteTimestamp", (const char *) funcName, sizeof("xglCmdWriteTimestamp")))
1324 return xglCmdWriteTimestamp;
1325 else if (!strncmp("xglCmdInitAtomicCounters", (const char *) funcName, sizeof("xglCmdInitAtomicCounters")))
1326 return xglCmdInitAtomicCounters;
1327 else if (!strncmp("xglCmdLoadAtomicCounters", (const char *) funcName, sizeof("xglCmdLoadAtomicCounters")))
1328 return xglCmdLoadAtomicCounters;
1329 else if (!strncmp("xglCmdSaveAtomicCounters", (const char *) funcName, sizeof("xglCmdSaveAtomicCounters")))
1330 return xglCmdSaveAtomicCounters;
1331 else if (!strncmp("xglDbgSetValidationLevel", (const char *) funcName, sizeof("xglDbgSetValidationLevel")))
1332 return xglDbgSetValidationLevel;
1333 else if (!strncmp("xglDbgRegisterMsgCallback", (const char *) funcName, sizeof("xglDbgRegisterMsgCallback")))
1334 return xglDbgRegisterMsgCallback;
1335 else if (!strncmp("xglDbgUnregisterMsgCallback", (const char *) funcName, sizeof("xglDbgUnregisterMsgCallback")))
1336 return xglDbgUnregisterMsgCallback;
1337 else if (!strncmp("xglDbgSetMessageFilter", (const char *) funcName, sizeof("xglDbgSetMessageFilter")))
1338 return xglDbgSetMessageFilter;
1339 else if (!strncmp("xglDbgSetObjectTag", (const char *) funcName, sizeof("xglDbgSetObjectTag")))
1340 return xglDbgSetObjectTag;
1341 else if (!strncmp("xglDbgSetGlobalOption", (const char *) funcName, sizeof("xglDbgSetGlobalOption")))
1342 return xglDbgSetGlobalOption;
1343 else if (!strncmp("xglDbgSetDeviceOption", (const char *) funcName, sizeof("xglDbgSetDeviceOption")))
1344 return xglDbgSetDeviceOption;
1345 else if (!strncmp("xglCmdDbgMarkerBegin", (const char *) funcName, sizeof("xglCmdDbgMarkerBegin")))
1346 return xglCmdDbgMarkerBegin;
1347 else if (!strncmp("xglCmdDbgMarkerEnd", (const char *) funcName, sizeof("xglCmdDbgMarkerEnd")))
1348 return xglCmdDbgMarkerEnd;
1349 else if (!strncmp("xglWsiX11AssociateConnection", (const char *) funcName, sizeof("xglWsiX11AssociateConnection")))
1350 return xglWsiX11AssociateConnection;
1351 else if (!strncmp("xglWsiX11GetMSC", (const char *) funcName, sizeof("xglWsiX11GetMSC")))
1352 return xglWsiX11GetMSC;
1353 else if (!strncmp("xglWsiX11CreatePresentableImage", (const char *) funcName, sizeof("xglWsiX11CreatePresentableImage")))
1354 return xglWsiX11CreatePresentableImage;
1355 else if (!strncmp("xglWsiX11QueuePresent", (const char *) funcName, sizeof("xglWsiX11QueuePresent")))
1356 return xglWsiX11QueuePresent;
1357 else {
1358 XGL_BASE_LAYER_OBJECT* gpuw = (XGL_BASE_LAYER_OBJECT *) gpu;
1359 if (gpuw->pGPA == NULL)
1360 return NULL;
1361 return gpuw->pGPA(gpuw->nextObject, funcName);
1362 }
1363}
1364