Add basic non-complete GL hooking on apple

* We implement this with dyld interposing. This means we must decide at compile
  time which functions to be hooked - in particular we require a manually
  curated list of functions that are actually exposed in the latest macOS GL
  version. Fortunately this is not a moving target anymore so this list should
  now be complete.
* The hooking is not complete:
  - It doesn't do full context tracking, just context create and make current
  - There's no drawable/window querying or tracking, so windows aren't properly processed and their size is wrong
* Also note that this does not support the replay side yet (CGLPlatform is still
  mostly stubs) and capturing actually still crashes.
This commit is contained in:
baldurk
2018-09-02 13:20:35 +01:00
parent 00d2bf62ff
commit bec9c56300
13 changed files with 1743 additions and 121 deletions
+5
View File
@@ -25,6 +25,11 @@ elseif(APPLE)
find_library(QUARTZCORE_LIBRARY QuartzCore)
list(APPEND RDOC_LIBRARIES PRIVATE ${QUARTZCORE_LIBRARY})
endif()
if(ENABLE_GL)
find_library(OPENGL_LIBRARY OpenGL)
list(APPEND RDOC_LIBRARIES PRIVATE ${OPENGL_LIBRARY})
endif()
elseif(UNIX)
find_package(PkgConfig REQUIRED)
find_package(Threads REQUIRED)
+1
View File
@@ -53,6 +53,7 @@ list(APPEND sources gl_hooks.cpp)
if(APPLE)
list(APPEND sources
cgl_dispatch_table.h
cgl_platform.cpp
cgl_hooks.cpp)
else()
File diff suppressed because it is too large Load Diff
+58
View File
@@ -0,0 +1,58 @@
/******************************************************************************
* The MIT License (MIT)
*
* Copyright (c) 2018 Baldur Karlsson
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE.
******************************************************************************/
#pragma once
#include "gl_common.h"
// cgl functions
typedef CGLError (*PFN_CGLCreateContext)(CGLPixelFormatObj pix, CGLContextObj share,
CGLContextObj *ctx);
typedef CGLError (*PFN_CGLSetCurrentContext)(CGLContextObj ctx);
typedef CGLError (*PFN_CGLFlushDrawable)(CGLContextObj ctx);
typedef CGLError (*PFN_CGLDestroyContext)(CGLContextObj ctx);
#define CGL_HOOKED_SYMBOLS(FUNC) \
FUNC(CGLCreateContext); \
FUNC(CGLSetCurrentContext); \
FUNC(CGLFlushDrawable);
#define CGL_NONHOOKED_SYMBOLS(FUNC) FUNC(CGLDestroyContext);
struct CGLDispatchTable
{
// Although not needed on macOS, for consistency we follow the same pattern as EGLDispatchTable
// and GLXDispatchTable.
bool PopulateForReplay();
// Generate the CGL function pointers. We need to consider hooked and non-hooked symbols separately
// - non-hooked symbols don't have a function hook to register, or if they do it's a dummy
// pass-through hook that will risk calling itself via trampoline.
#define CGL_PTR_GEN(func) CONCAT(PFN_, func) func;
CGL_HOOKED_SYMBOLS(CGL_PTR_GEN)
CGL_NONHOOKED_SYMBOLS(CGL_PTR_GEN)
#undef CGL_PTR_GEN
};
extern CGLDispatchTable CGL;
+161 -5
View File
@@ -22,12 +22,168 @@
* THE SOFTWARE.
******************************************************************************/
#include <dlfcn.h>
#include "OpenGL/OpenGL.h"
#include "hooks/hooks.h"
#include "cgl_dispatch_table.h"
#include "gl_driver.h"
class OpenGLHook : LibraryHook
class CGLHook : LibraryHook
{
public:
OpenGLHook() {}
~OpenGLHook() {}
void RegisterHooks() {}
};
CGLHook() : driver(GetGLPlatform()) {}
void RegisterHooks();
// default to RTLD_NEXT for CGL lookups if we haven't gotten a more specific library handle
void *handle = RTLD_NEXT;
WrappedOpenGL driver;
std::set<CGLContextObj> contexts;
} cglhook;
CGLError GL_EXPORT_NAME(CGLCreateContext)(CGLPixelFormatObj pix, CGLContextObj share,
CGLContextObj *ctx)
{
if(RenderDoc::Inst().IsReplayApp())
{
if(!CGL.CGLCreateContext)
CGL.PopulateForReplay();
return CGL.CGLCreateContext(pix, share, ctx);
}
CGLError ret = CGL.CGLCreateContext(pix, share, ctx);
if(ret != kCGLNoError)
return ret;
GLInitParams init;
init.width = 0;
init.height = 0;
int value = 0;
// GLX.glXGetConfig(dpy, vis, GLX_BUFFER_SIZE, &value);
init.colorBits = 32;
// GLX.glXGetConfig(dpy, vis, GLX_DEPTH_SIZE, &value);
init.depthBits = 24;
// GLX.glXGetConfig(dpy, vis, GLX_STENCIL_SIZE, &value);
init.stencilBits = 8;
value = 1; // default to srgb
// GLX.glXGetConfig(dpy, vis, GLX_FRAMEBUFFER_SRGB_CAPABLE_ARB, &value);
init.isSRGB = value;
value = 1;
// GLX.glXGetConfig(dpy, vis, GLX_SAMPLES_ARB, &value);
init.isSRGB = RDCMAX(1, value);
GLWindowingData data;
data.wnd = NULL;
data.ctx = *ctx;
// data.cfg = pix;
{
SCOPED_LOCK(glLock);
cglhook.driver.CreateContext(data, share, init, true, true);
}
return ret;
}
CGLError GL_EXPORT_NAME(CGLSetCurrentContext)(CGLContextObj ctx)
{
if(RenderDoc::Inst().IsReplayApp())
{
if(!CGL.CGLSetCurrentContext)
CGL.PopulateForReplay();
return CGL.CGLSetCurrentContext(ctx);
}
CGLError ret = CGL.CGLSetCurrentContext(ctx);
if(ret == kCGLNoError)
{
SCOPED_LOCK(glLock);
SetDriverForHooks(&cglhook.driver);
if(ctx && cglhook.contexts.find(ctx) == cglhook.contexts.end())
{
cglhook.contexts.insert(ctx);
FetchEnabledExtensions();
// see gl_emulated.cpp
GL.EmulateUnsupportedFunctions();
GL.EmulateRequiredExtensions();
GL.DriverForEmulation(&cglhook.driver);
}
GLWindowingData data;
data.wnd = (void *)0x4; // drawable;
data.ctx = ctx;
// data.cfg = NULL;
cglhook.driver.ActivateContext(data);
}
return ret;
}
CGLError GL_EXPORT_NAME(CGLFlushDrawable)(CGLContextObj ctx)
{
if(RenderDoc::Inst().IsReplayApp())
{
if(!CGL.CGLFlushDrawable)
CGL.PopulateForReplay();
return CGL.CGLFlushDrawable(ctx);
}
SCOPED_LOCK(glLock);
cglhook.driver.WindowSize((void *)0x4, 800, 200);
cglhook.driver.SwapBuffers((void *)0x4);
return CGL.CGLFlushDrawable(ctx);
}
DECL_GL_HOOK_EXPORT(CGLCreateContext);
DECL_GL_HOOK_EXPORT(CGLSetCurrentContext);
DECL_GL_HOOK_EXPORT(CGLFlushDrawable);
static void CGLHooked(void *handle)
{
RDCDEBUG("CGL library hooked");
// store the handle for any pass-through implementations that need to look up their onward
// pointers
cglhook.handle = handle;
// as a hook callback this is only called while capturing
RDCASSERT(!RenderDoc::Inst().IsReplayApp());
// fetch non-hooked functions into our dispatch table
#define CGL_FETCH(func) CGL.func = &func;
CGL_NONHOOKED_SYMBOLS(CGL_FETCH)
#undef CGL_FETCH
}
void CGLHook::RegisterHooks()
{
RDCLOG("Registering CGL hooks");
// register library hooks
LibraryHooks::RegisterLibraryHook(
"/System/Library/Frameworks/OpenGL.framework/Versions/Current/OpenGL", &CGLHooked);
LibraryHooks::RegisterLibraryHook("libGL.dylib", NULL);
// register CGL hooks
#define CGL_REGISTER(func) \
LibraryHooks::RegisterFunctionHook("OpenGL", \
FunctionHook(STRINGIZE(func), (void **)&CGL.func, \
(void *)&GL_EXPORT_NAME(CGLFlushDrawable)));
CGL_HOOKED_SYMBOLS(CGL_REGISTER)
#undef CGL_REGISTER
}
+10 -1
View File
@@ -22,7 +22,9 @@
* THE SOFTWARE.
******************************************************************************/
#include "driver/gl/gl_common.h"
#include <OpenGL/OpenGL.h>
#include "cgl_dispatch_table.h"
#include "gl_common.h"
class CGLPlatform : public GLPlatform
{
@@ -55,7 +57,14 @@ class CGLPlatform : public GLPlatform
void DrawQuads(float width, float height, const std::vector<Vec4f> &vertices) {}
} cglPlatform;
CGLDispatchTable CGL = {};
GLPlatform &GetGLPlatform()
{
return cglPlatform;
}
bool CGLDispatchTable::PopulateForReplay()
{
return false;
}
+9 -6
View File
@@ -224,10 +224,11 @@ template = '''
UNINIT_CALL(function, {argpass}); \\
return glhook.driver->function({argpass}); \\
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl}) \\
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)({argdecl}) \\
{{ \\
return CONCAT(function, _renderdoc_hooked)({argpass}); \\
}}
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl});
#define AliasWrapper{num}(ret, function, realfunc{macroargs}) \\
ret HOOK_CC CONCAT(function, _renderdoc_hooked)({argdecl}) \\
@@ -236,10 +237,11 @@ template = '''
UNINIT_CALL(realfunc, {argpass}); \\
return glhook.driver->realfunc({argpass}); \\
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl}) \\
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)({argdecl}) \\
{{ \\
return CONCAT(function, _renderdoc_hooked)({argpass}); \\
}}
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl});
#define UnsupportedWrapper{num}(ret, function{macroargs}) \\
typedef ret(HOOK_CC *CONCAT(function, _hooktype))({argdecl}); \\
@@ -257,10 +259,11 @@ template = '''
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \\
return CONCAT(unsupported_real_, function)({argpass}); \\
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl}) \\
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)({argdecl}) \\
{{ \\
return CONCAT(function, _renderdoc_hooked)({argpass}); \\
}}
}} \\
HOOK_EXPORT ret HOOK_CC function({argdecl});
'''
for num in range(parsed_args.maxparam+1):
+26
View File
@@ -306,6 +306,32 @@ GLPlatform &GetEGLPlatform();
#endif
// on macOS we used compile time interposing to hook
#if ENABLED(RDOC_APPLE)
// never declare the actual raw function name as an export, declare the functions with a suffix that
// will be connected in the struct below
#define GL_EXPORT_NAME(function) CONCAT(interposed_, function)
// from dyld-interposing.h - DYLD_INTERPOSE
#define DECL_GL_HOOK_EXPORT(function) \
__attribute__((used)) static struct \
{ \
const void *replacment; \
const void *replacee; \
} _interpose_def_##function __attribute__((section("__DATA,__interpose"))) = { \
(const void *)(unsigned long)&GL_EXPORT_NAME(function), (const void *)(unsigned long)&function, \
};
#else
// on all other platforms we just export functions with the bare name, and don't declare anything to
// hook.
#define GL_EXPORT_NAME(function) function
#define DECL_GL_HOOK_EXPORT(function)
#endif
class RDCFile;
class IReplayDriver;
+162 -108
View File
@@ -6392,10 +6392,11 @@
UNINIT_CALL(function, ); \
return glhook.driver->function(); \
} \
HOOK_EXPORT ret HOOK_CC function() \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)() \
{ \
return CONCAT(function, _renderdoc_hooked)(); \
}
} \
HOOK_EXPORT ret HOOK_CC function();
#define AliasWrapper0(ret, function, realfunc) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)() \
@@ -6404,10 +6405,11 @@
UNINIT_CALL(realfunc, ); \
return glhook.driver->realfunc(); \
} \
HOOK_EXPORT ret HOOK_CC function() \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)() \
{ \
return CONCAT(function, _renderdoc_hooked)(); \
}
} \
HOOK_EXPORT ret HOOK_CC function();
#define UnsupportedWrapper0(ret, function) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(); \
@@ -6425,10 +6427,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(); \
} \
HOOK_EXPORT ret HOOK_CC function() \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)() \
{ \
return CONCAT(function, _renderdoc_hooked)(); \
}
} \
HOOK_EXPORT ret HOOK_CC function();
#define FuncWrapper1(ret, function, t1, p1) \
@@ -6438,10 +6441,11 @@
UNINIT_CALL(function, p1); \
return glhook.driver->function(p1); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1);
#define AliasWrapper1(ret, function, realfunc, t1, p1) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1) \
@@ -6450,10 +6454,11 @@
UNINIT_CALL(realfunc, p1); \
return glhook.driver->realfunc(p1); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1);
#define UnsupportedWrapper1(ret, function, t1, p1) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1); \
@@ -6471,10 +6476,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1);
#define FuncWrapper2(ret, function, t1, p1, t2, p2) \
@@ -6484,10 +6490,11 @@
UNINIT_CALL(function, p1, p2); \
return glhook.driver->function(p1, p2); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2);
#define AliasWrapper2(ret, function, realfunc, t1, p1, t2, p2) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2) \
@@ -6496,10 +6503,11 @@
UNINIT_CALL(realfunc, p1, p2); \
return glhook.driver->realfunc(p1, p2); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2);
#define UnsupportedWrapper2(ret, function, t1, p1, t2, p2) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2); \
@@ -6517,10 +6525,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2);
#define FuncWrapper3(ret, function, t1, p1, t2, p2, t3, p3) \
@@ -6530,10 +6539,11 @@
UNINIT_CALL(function, p1, p2, p3); \
return glhook.driver->function(p1, p2, p3); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3);
#define AliasWrapper3(ret, function, realfunc, t1, p1, t2, p2, t3, p3) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3) \
@@ -6542,10 +6552,11 @@
UNINIT_CALL(realfunc, p1, p2, p3); \
return glhook.driver->realfunc(p1, p2, p3); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3);
#define UnsupportedWrapper3(ret, function, t1, p1, t2, p2, t3, p3) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3); \
@@ -6563,10 +6574,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3);
#define FuncWrapper4(ret, function, t1, p1, t2, p2, t3, p3, t4, p4) \
@@ -6576,10 +6588,11 @@
UNINIT_CALL(function, p1, p2, p3, p4); \
return glhook.driver->function(p1, p2, p3, p4); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4);
#define AliasWrapper4(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4) \
@@ -6588,10 +6601,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4); \
return glhook.driver->realfunc(p1, p2, p3, p4); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4);
#define UnsupportedWrapper4(ret, function, t1, p1, t2, p2, t3, p3, t4, p4) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4); \
@@ -6609,10 +6623,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4);
#define FuncWrapper5(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5) \
@@ -6622,10 +6637,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5); \
return glhook.driver->function(p1, p2, p3, p4, p5); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5);
#define AliasWrapper5(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
@@ -6634,10 +6650,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5);
#define UnsupportedWrapper5(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5); \
@@ -6655,10 +6672,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5);
#define FuncWrapper6(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6) \
@@ -6668,10 +6686,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6);
#define AliasWrapper6(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
@@ -6680,10 +6699,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6);
#define UnsupportedWrapper6(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6); \
@@ -6701,10 +6721,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6);
#define FuncWrapper7(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7) \
@@ -6714,10 +6735,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7);
#define AliasWrapper7(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
@@ -6726,10 +6748,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7);
#define UnsupportedWrapper7(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7); \
@@ -6747,10 +6770,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7);
#define FuncWrapper8(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8) \
@@ -6760,10 +6784,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8);
#define AliasWrapper8(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
@@ -6772,10 +6797,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8);
#define UnsupportedWrapper8(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8); \
@@ -6793,10 +6819,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8);
#define FuncWrapper9(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9) \
@@ -6806,10 +6833,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9);
#define AliasWrapper9(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
@@ -6818,10 +6846,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9);
#define UnsupportedWrapper9(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9); \
@@ -6839,10 +6868,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9);
#define FuncWrapper10(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10) \
@@ -6852,10 +6882,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10);
#define AliasWrapper10(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
@@ -6864,10 +6895,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10);
#define UnsupportedWrapper10(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10); \
@@ -6885,10 +6917,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10);
#define FuncWrapper11(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11) \
@@ -6898,10 +6931,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11);
#define AliasWrapper11(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
@@ -6910,10 +6944,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11);
#define UnsupportedWrapper11(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11); \
@@ -6931,10 +6966,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11);
#define FuncWrapper12(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12) \
@@ -6944,10 +6980,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12);
#define AliasWrapper12(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
@@ -6956,10 +6993,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12);
#define UnsupportedWrapper12(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12); \
@@ -6977,10 +7015,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12);
#define FuncWrapper13(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13) \
@@ -6990,10 +7029,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13);
#define AliasWrapper13(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
@@ -7002,10 +7042,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13);
#define UnsupportedWrapper13(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13); \
@@ -7023,10 +7064,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13);
#define FuncWrapper14(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14) \
@@ -7036,10 +7078,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14);
#define AliasWrapper14(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
@@ -7048,10 +7091,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14);
#define UnsupportedWrapper14(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14); \
@@ -7069,10 +7113,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14);
#define FuncWrapper15(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15) \
@@ -7082,10 +7127,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15);
#define AliasWrapper15(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
@@ -7094,10 +7140,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15);
#define UnsupportedWrapper15(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15); \
@@ -7115,10 +7162,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15);
#define FuncWrapper16(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16) \
@@ -7128,10 +7176,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16);
#define AliasWrapper16(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
@@ -7140,10 +7189,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16);
#define UnsupportedWrapper16(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16); \
@@ -7161,10 +7211,11 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16);
#define FuncWrapper17(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16, t17, p17) \
@@ -7174,10 +7225,11 @@
UNINIT_CALL(function, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
return glhook.driver->function(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17);
#define AliasWrapper17(ret, function, realfunc, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16, t17, p17) \
ret HOOK_CC CONCAT(function, _renderdoc_hooked)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
@@ -7186,10 +7238,11 @@
UNINIT_CALL(realfunc, p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
return glhook.driver->realfunc(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17);
#define UnsupportedWrapper17(ret, function, t1, p1, t2, p2, t3, p3, t4, p4, t5, p5, t6, p6, t7, p7, t8, p8, t9, p9, t10, p10, t11, p11, t12, p12, t13, p13, t14, p14, t15, p15, t16, p16, t17, p17) \
typedef ret(HOOK_CC *CONCAT(function, _hooktype))(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17); \
@@ -7207,8 +7260,9 @@
(CONCAT(function, _hooktype))glhook.GetUnsupportedFunction(STRINGIZE(function)); \
return CONCAT(unsupported_real_, function)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
HOOK_EXPORT ret HOOK_CC GL_EXPORT_NAME(function)(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17) \
{ \
return CONCAT(function, _renderdoc_hooked)(p1, p2, p3, p4, p5, p6, p7, p8, p9, p10, p11, p12, p13, p14, p15, p16, p17); \
}
} \
HOOK_EXPORT ret HOOK_CC function(t1 p1, t2 p2, t3 p3, t4 p4, t5 p5, t6 p6, t7 p7, t8 p8, t9 p9, t10 p10, t11 p11, t12 p12, t13 p13, t14 p14, t15 p15, t16 p16, t17 p17);
+6
View File
@@ -197,6 +197,8 @@ void GLHook::RegisterHooks()
const char *libraryName = "opengl32.dll";
#elif ENABLED(RDOC_ANDROID)
const char *libraryName = "libEGL.so";
#elif ENABLED(RDOC_APPLE)
const char *libraryName = "/System/Library/Frameworks/OpenGL.framework/Versions/Current/OpenGL";
#else
const char *libraryName = "libGL.so.1";
#endif
@@ -221,3 +223,7 @@ void GLHook::RegisterHooks()
}
#endif
}
#if ENABLED(RDOC_APPLE)
#include "apple_gl_hook_defs.h"
#endif
+1 -1
View File
@@ -22,8 +22,8 @@
* THE SOFTWARE.
******************************************************************************/
#include "driver/gl/gl_dispatch_table_defs.h"
#include "gl_common.h"
#include "gl_dispatch_table_defs.h"
#include "gl_driver.h"
template <>
+2
View File
@@ -98,6 +98,8 @@
</Link>
</ItemDefinitionGroup>
<ItemGroup>
<ClInclude Include="apple_gl_hook_defs.h" />
<ClInclude Include="cgl_dispatch_table.h" />
<ClInclude Include="glx_dispatch_table.h" />
<ClInclude Include="gl_common.h" />
<ClInclude Include="gl_driver.h" />
@@ -117,6 +117,12 @@
<ClInclude Include="glx_dispatch_table.h">
<Filter>Platform Interfaces\Linux</Filter>
</ClInclude>
<ClInclude Include="cgl_dispatch_table.h">
<Filter>Platform Interfaces\Apple</Filter>
</ClInclude>
<ClInclude Include="apple_gl_hook_defs.h">
<Filter>Platform Interfaces\Apple</Filter>
</ClInclude>
</ItemGroup>
<ItemGroup>
<ClCompile Include="wrappers\gl_buffer_funcs.cpp">