mirror of
https://github.com/ptitSeb/box64.git
synced 2024-11-27 00:30:32 +00:00
[BOX32] Added (mostly untested) wrapped libGL and minimum SDL1 (SDLgears and zsnes works)
This commit is contained in:
parent
b361a0d2ff
commit
de7baa0b41
@ -400,6 +400,7 @@ if(BOX32)
|
||||
"${BOX64_ROOT}/src/libtools/signal32.c"
|
||||
"${BOX64_ROOT}/src/libtools/threads32.c"
|
||||
"${BOX64_ROOT}/src/libtools/libc_net32.c"
|
||||
"${BOX64_ROOT}/src/libtools/sdl1align32.c"
|
||||
"${BOX64_ROOT}/src/emu/x86syscall_32.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/generated/wrapper32.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/generated/converter32.c"
|
||||
@ -782,6 +783,8 @@ if(BOX32)
|
||||
"${BOX64_ROOT}/src/wrapped32/wrappedlibpthread.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/wrappedlibrt.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/wrappedcrashhandler.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/wrappedlibgl.c"
|
||||
"${BOX64_ROOT}/src/wrapped32/wrappedsdl1.c"
|
||||
)
|
||||
endif()
|
||||
string(REPLACE ".c" "_private.h" MODROOT ${BOX64_ROOT})
|
||||
|
@ -9,4 +9,8 @@ void freeGLProcWrapper(box64context_t* context);
|
||||
|
||||
void* getGLProcAddress(x64emu_t* emu, glprocaddress_t procaddr, const char* rname);
|
||||
|
||||
#ifdef BOX32
|
||||
void* getGLProcAddress32(x64emu_t* emu, glprocaddress_t procaddr, const char* rname);
|
||||
#endif
|
||||
|
||||
#endif //__GL_TOOLS_H__
|
498
src/include/sdl1align32.h
Normal file
498
src/include/sdl1align32.h
Normal file
@ -0,0 +1,498 @@
|
||||
#ifndef __MY_SDL1ALIGN32_H_
|
||||
#define __MY_SDL1ALIGN32_H_
|
||||
#include <stdint.h>
|
||||
#include "box32.h"
|
||||
|
||||
typedef struct my_SDL_Rect_s
|
||||
{
|
||||
int16_t x;
|
||||
int16_t y;
|
||||
uint16_t w;
|
||||
uint16_t h;
|
||||
} my_SDL_Rect_t;
|
||||
|
||||
typedef struct my_SDL_Color_s
|
||||
{
|
||||
uint8_t r;
|
||||
uint8_t g;
|
||||
uint8_t b;
|
||||
uint8_t unused;
|
||||
} my_SDL_Color_t;
|
||||
|
||||
typedef struct my_SDL_Palette_s
|
||||
{
|
||||
int ncolors;
|
||||
my_SDL_Color_t *colors;
|
||||
} my_SDL_Palette_t;
|
||||
|
||||
typedef struct my_SDL_PixelFormat_s
|
||||
{
|
||||
my_SDL_Palette_t *palette;
|
||||
uint8_t BitsPerPixel;
|
||||
uint8_t BytesPerPixel;
|
||||
uint8_t Rloss;
|
||||
uint8_t Gloss;
|
||||
uint8_t Bloss;
|
||||
uint8_t Aloss;
|
||||
uint8_t Rshift;
|
||||
uint8_t Gshift;
|
||||
uint8_t Bshift;
|
||||
uint8_t Ashift;
|
||||
uint32_t Rmask;
|
||||
uint32_t Gmask;
|
||||
uint32_t Bmask;
|
||||
uint32_t Amask;
|
||||
uint32_t colorkey;
|
||||
uint8_t alpha;
|
||||
} my_SDL_PixelFormat_t;
|
||||
|
||||
typedef struct my_SDL_Surface_s
|
||||
{
|
||||
uint32_t flags;
|
||||
my_SDL_PixelFormat_t *format;
|
||||
int w;
|
||||
int h;
|
||||
uint16_t pitch;
|
||||
void *pixels;
|
||||
int offset;
|
||||
void* hwdata; //struct private_hwdata
|
||||
my_SDL_Rect_t clip_rect;
|
||||
uint32_t unused1;
|
||||
uint32_t locked;
|
||||
void *map;
|
||||
unsigned int format_version;
|
||||
int refcount;
|
||||
} my_SDL_Surface_t;
|
||||
|
||||
// x86 version (packed, 32bits pointers and long)
|
||||
|
||||
typedef struct __attribute__((packed)) my_SDL_Rect_32_s
|
||||
{
|
||||
int16_t x;
|
||||
int16_t y;
|
||||
uint16_t w;
|
||||
uint16_t h;
|
||||
} my_SDL_Rect_32_t;
|
||||
|
||||
typedef struct __attribute__((packed)) my_SDL_Color_32_s
|
||||
{
|
||||
uint8_t r;
|
||||
uint8_t g;
|
||||
uint8_t b;
|
||||
uint8_t unused;
|
||||
} my_SDL_Color_32_t;
|
||||
|
||||
typedef struct __attribute__((packed)) my_SDL_Palette_32_s
|
||||
{
|
||||
int ncolors;
|
||||
ptr_t colors; // my_SDL_Color_t*
|
||||
} my_SDL_Palette_32_t;
|
||||
|
||||
typedef struct __attribute__((packed)) my_SDL_PixelFormat_32_s
|
||||
{
|
||||
ptr_t palette; // my_SDL_Palette_t *
|
||||
uint8_t BitsPerPixel;
|
||||
uint8_t BytesPerPixel;
|
||||
uint8_t Rloss;
|
||||
uint8_t Gloss;
|
||||
uint8_t Bloss;
|
||||
uint8_t Aloss;
|
||||
uint8_t Rshift;
|
||||
uint8_t Gshift;
|
||||
uint8_t Bshift;
|
||||
uint8_t Ashift;
|
||||
uint32_t Rmask;
|
||||
uint32_t Gmask;
|
||||
uint32_t Bmask;
|
||||
uint32_t Amask;
|
||||
uint32_t colorkey;
|
||||
uint8_t alpha;
|
||||
} my_SDL_PixelFormat_32_t;
|
||||
|
||||
typedef struct __attribute__((packed)) my_SDL_Surface_32_s
|
||||
{
|
||||
uint32_t flags;
|
||||
ptr_t format; // my_SDL_PixelFormat_t *
|
||||
int w;
|
||||
int h;
|
||||
uint16_t pitch;
|
||||
uint16_t dummy;
|
||||
ptr_t pixels; // void *
|
||||
int offset;
|
||||
ptr_t hwdata; //struct private_hwdata*
|
||||
my_SDL_Rect_t clip_rect;
|
||||
uint32_t unused1;
|
||||
uint32_t locked;
|
||||
ptr_t map; // void *
|
||||
unsigned int format_version;
|
||||
int refcount;
|
||||
} my_SDL_Surface_32_t;
|
||||
|
||||
void inplace_SDL_Surface_to_64(void* a);
|
||||
void inplace_SDL_Surface_to_32(void* a);
|
||||
void inplace_SDL_PixelFormat_to_64(void* a);
|
||||
void inplace_SDL_PixelFormat_to_32(void* a);
|
||||
void inplace_SDL_Palette_to_64(void* a);
|
||||
void inplace_SDL_Palette_to_32(void* a);
|
||||
|
||||
typedef struct my_SDL_keysym_s
|
||||
{
|
||||
uint8_t scancode;
|
||||
int sym;
|
||||
int mod;
|
||||
uint16_t unicode;
|
||||
} my_SDL_keysym_t;
|
||||
|
||||
typedef struct my_SDL_keysym_32_s
|
||||
{
|
||||
uint8_t scancode;
|
||||
int sym;
|
||||
int mod;
|
||||
uint16_t unicode;
|
||||
} my_SDL_keysym_32_t;
|
||||
|
||||
|
||||
typedef enum my_SDL_EventType_s
|
||||
{
|
||||
SDL_NOEVENT,
|
||||
SDL_ACTIVEEVENT,
|
||||
SDL_KEYDOWN,
|
||||
SDL_KEYUP,
|
||||
SDL_MOUSEMOTION,
|
||||
SDL_MOUSEBUTTONDOWN,
|
||||
SDL_MOUSEBUTTONUP,
|
||||
SDL_JOYAXISMOTION,
|
||||
SDL_JOYBALLMOTION,
|
||||
SDL_JOYHATMOTION,
|
||||
SDL_JOYBUTTONDOWN,
|
||||
SDL_JOYBUTTONUP,
|
||||
SDL_QUIT,
|
||||
SDL_SYSWMEVENT,
|
||||
SDL_EVENT_RESERVEDA,
|
||||
SDL_EVENT_RESERVEDB,
|
||||
SDL_VIDEORESIZE,
|
||||
SDL_VIDEOEXPOSE,
|
||||
SDL_EVENT_RESERVED2,
|
||||
SDL_EVENT_RESERVED3,
|
||||
SDL_EVENT_RESERVED4,
|
||||
SDL_EVENT_RESERVED5,
|
||||
SDL_EVENT_RESERVED6,
|
||||
SDL_EVENT_RESERVED7,
|
||||
SDL_USEREVENT = 24,
|
||||
SDL_NUMEVENTS = 32
|
||||
} my_SDL_EventType_t;
|
||||
|
||||
typedef struct my_SDL_ActiveEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t gain;
|
||||
uint8_t state;
|
||||
} my_SDL_ActiveEvent_t;
|
||||
|
||||
typedef struct my_SDL_KeyboardEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t state;
|
||||
my_SDL_keysym_t keysym;
|
||||
} my_SDL_KeyboardEvent_t;
|
||||
|
||||
typedef struct my_SDL_MouseMotionEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t state;
|
||||
uint16_t x;
|
||||
uint16_t y;
|
||||
int16_t xrel;
|
||||
int16_t yrel;
|
||||
} my_SDL_MouseMotionEvent_t;
|
||||
|
||||
typedef struct my_SDL_MouseButtonEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t button;
|
||||
uint8_t state;
|
||||
uint16_t x;
|
||||
uint16_t y;
|
||||
} my_SDL_MouseButtonEvent_t;
|
||||
|
||||
typedef struct my_SDL_JoyAxisEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t axis;
|
||||
int16_t value;
|
||||
} my_SDL_JoyAxisEvent_t;
|
||||
|
||||
typedef struct my_SDL_JoyBallEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t ball;
|
||||
int16_t xrel;
|
||||
int16_t yrel;
|
||||
} my_SDL_JoyBallEvent_t;
|
||||
|
||||
typedef struct my_SDL_JoyHatEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t hat;
|
||||
uint8_t value;
|
||||
} my_SDL_JoyHatEvent_t;
|
||||
|
||||
typedef struct my_SDL_JoyButtonEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t button;
|
||||
uint8_t state;
|
||||
} my_SDL_JoyButtonEvent_t;
|
||||
|
||||
typedef struct my_SDL_ResizeEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
int w;
|
||||
int h;
|
||||
} my_SDL_ResizeEvent_t;
|
||||
|
||||
typedef struct my_SDL_ExposeEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
} my_SDL_ExposeEvent_t;
|
||||
|
||||
typedef struct my_SDL_QuitEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
} my_SDL_QuitEvent_t;
|
||||
|
||||
typedef struct my_SDL_UserEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
int code;
|
||||
void *data1;
|
||||
void *data2;
|
||||
} my_SDL_UserEvent_t;
|
||||
|
||||
typedef struct my_SDL_version_s {
|
||||
uint8_t major;
|
||||
uint8_t minor;
|
||||
uint8_t patch;
|
||||
} my_SDL_version_t;
|
||||
|
||||
typedef struct my_SDL_SysWMinfo_s {
|
||||
my_SDL_version_t version;
|
||||
int subsystem;
|
||||
union {
|
||||
struct {
|
||||
void* display;
|
||||
void* window;
|
||||
void (*lock_func)(void);
|
||||
void (*unlock_func)(void);
|
||||
void* fswindow;
|
||||
void* wmwindow;
|
||||
void* gfxdisplay;
|
||||
} x11;
|
||||
} info;
|
||||
} my_SDL_SysWMinfo_t;
|
||||
|
||||
typedef union my_XEvent_s {
|
||||
int Type;
|
||||
long pad[24];
|
||||
} my_XEvent_t;
|
||||
|
||||
typedef struct my_SDL_SysWMmsg_s
|
||||
{
|
||||
my_SDL_version_t version;
|
||||
int subsystem;
|
||||
union {
|
||||
my_XEvent_t xevent;
|
||||
} event;
|
||||
} my_SDL_SysWMmsg_t;
|
||||
|
||||
|
||||
typedef struct my_SDL_SysWMEvent_s
|
||||
{
|
||||
uint8_t type;
|
||||
my_SDL_SysWMmsg_t *msg;
|
||||
} my_SDL_SysWMEvent_t;
|
||||
|
||||
typedef union my_SDL_Event_s
|
||||
{
|
||||
uint8_t type;
|
||||
my_SDL_ActiveEvent_t active;
|
||||
my_SDL_KeyboardEvent_t key;
|
||||
my_SDL_MouseMotionEvent_t motion;
|
||||
my_SDL_MouseButtonEvent_t button;
|
||||
my_SDL_JoyAxisEvent_t jaxis;
|
||||
my_SDL_JoyBallEvent_t jball;
|
||||
my_SDL_JoyHatEvent_t jhat;
|
||||
my_SDL_JoyButtonEvent_t jbutton;
|
||||
my_SDL_ResizeEvent_t resize;
|
||||
my_SDL_ExposeEvent_t expose;
|
||||
my_SDL_QuitEvent_t quit;
|
||||
my_SDL_UserEvent_t user;
|
||||
my_SDL_SysWMEvent_t syswm;
|
||||
} my_SDL_Event_t;
|
||||
|
||||
typedef struct my_SDL_ActiveEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t gain;
|
||||
uint8_t state;
|
||||
} my_SDL_ActiveEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_KeyboardEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t state;
|
||||
my_SDL_keysym_32_t keysym;
|
||||
} my_SDL_KeyboardEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_MouseMotionEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t state;
|
||||
uint16_t x;
|
||||
uint16_t y;
|
||||
int16_t xrel;
|
||||
int16_t yrel;
|
||||
} my_SDL_MouseMotionEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_MouseButtonEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t button;
|
||||
uint8_t state;
|
||||
uint16_t x;
|
||||
uint16_t y;
|
||||
} my_SDL_MouseButtonEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_JoyAxisEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t axis;
|
||||
int16_t value;
|
||||
} my_SDL_JoyAxisEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_JoyBallEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t ball;
|
||||
int16_t xrel;
|
||||
int16_t yrel;
|
||||
} my_SDL_JoyBallEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_JoyHatEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t hat;
|
||||
uint8_t value;
|
||||
} my_SDL_JoyHatEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_JoyButtonEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
uint8_t which;
|
||||
uint8_t button;
|
||||
uint8_t state;
|
||||
} my_SDL_JoyButtonEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_ResizeEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
int w;
|
||||
int h;
|
||||
} my_SDL_ResizeEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_ExposeEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
} my_SDL_ExposeEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_QuitEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
} my_SDL_QuitEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_UserEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
int code;
|
||||
ptr_t data1; //void*
|
||||
ptr_t data2; //void*
|
||||
} my_SDL_UserEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_version_32_s {
|
||||
uint8_t major;
|
||||
uint8_t minor;
|
||||
uint8_t patch;
|
||||
} my_SDL_version_32_t;
|
||||
|
||||
typedef struct my_SDL_SysWMinfo_32_s {
|
||||
my_SDL_version_32_t version;
|
||||
int subsystem;
|
||||
union {
|
||||
struct {
|
||||
ptr_t display; //void*
|
||||
ptr_t window; //void*
|
||||
ptr_t lock_func;//void (*lock_func)(void);
|
||||
ptr_t unlock_func;//void (*unlock_func)(void);
|
||||
ptr_t fswindow; //void*
|
||||
ptr_t wmwindow; //void*
|
||||
ptr_t gfxdisplay; //void*
|
||||
} x11;
|
||||
} info;
|
||||
} my_SDL_SysWMinfo_32_t;
|
||||
|
||||
typedef union my_XEvent_32_s {
|
||||
int Type;
|
||||
long_t pad[24];
|
||||
} my_XEvent_32_t;
|
||||
|
||||
typedef struct my_SDL_SysWMmsg_32_s
|
||||
{
|
||||
my_SDL_version_32_t version;
|
||||
int subsystem;
|
||||
union {
|
||||
my_XEvent_32_t xevent;
|
||||
} event;
|
||||
} my_SDL_SysWMmsg_32_t;
|
||||
|
||||
|
||||
typedef struct my_SDL_SysWMEvent_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
ptr_t msg; //my_SDL_SysWMmsg_t*
|
||||
} my_SDL_SysWMEvent_32_t;
|
||||
|
||||
typedef union my_SDL_Event_32_s
|
||||
{
|
||||
uint8_t type;
|
||||
my_SDL_ActiveEvent_32_t active;
|
||||
my_SDL_KeyboardEvent_32_t key;
|
||||
my_SDL_MouseMotionEvent_32_t motion;
|
||||
my_SDL_MouseButtonEvent_32_t button;
|
||||
my_SDL_JoyAxisEvent_32_t jaxis;
|
||||
my_SDL_JoyBallEvent_32_t jball;
|
||||
my_SDL_JoyHatEvent_32_t jhat;
|
||||
my_SDL_JoyButtonEvent_32_t jbutton;
|
||||
my_SDL_ResizeEvent_32_t resize;
|
||||
my_SDL_ExposeEvent_32_t expose;
|
||||
my_SDL_QuitEvent_32_t quit;
|
||||
my_SDL_UserEvent_32_t user;
|
||||
my_SDL_SysWMEvent_32_t syswm;
|
||||
} my_SDL_Event_32_t;
|
||||
|
||||
|
||||
void convert_SDL_Event_to_32(void* dst, const void* src);
|
||||
|
||||
#endif//__MY_SDL1ALIGN32_H_
|
@ -9,4 +9,8 @@ GO("libm.so.6", libm)
|
||||
GO("libdl.so.2", libdl)
|
||||
GO("ld-linux.so.2", ldlinux)
|
||||
|
||||
GO("libGL.so", libgl)
|
||||
GO("libGL.so.1", libgl)
|
||||
GO("libSDL-1.2.so.0", sdl1)
|
||||
|
||||
GO("crashhandler.so", crashhandler)
|
||||
|
165
src/libtools/sdl1align32.c
Normal file
165
src/libtools/sdl1align32.c
Normal file
@ -0,0 +1,165 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include <wchar.h>
|
||||
#include <sys/epoll.h>
|
||||
#include <fts.h>
|
||||
#include <sys/socket.h>
|
||||
|
||||
#include "x64emu.h"
|
||||
#include "emu/x64emu_private.h"
|
||||
#include "myalign32.h"
|
||||
#include "debug.h"
|
||||
#include "box32.h"
|
||||
#include "sdl1align32.h"
|
||||
|
||||
|
||||
void inplace_SDL_Palette_to_64(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_Palette_32_t* src = a;
|
||||
my_SDL_Palette_t* dst = a;
|
||||
dst->colors = from_ptrv(src->colors);
|
||||
}
|
||||
void inplace_SDL_Palette_to_32(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_Palette_t* src = a;
|
||||
my_SDL_Palette_32_t* dst = a;
|
||||
dst->colors = to_ptrv(src->colors);
|
||||
}
|
||||
void inplace_SDL_PixelFormat_to_64(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_PixelFormat_32_t* src = a;
|
||||
my_SDL_PixelFormat_t* dst = a;
|
||||
memmove(&dst->BitsPerPixel, &src->BitsPerPixel, sizeof(my_SDL_PixelFormat_t)-offsetof(my_SDL_PixelFormat_t, BitsPerPixel));
|
||||
dst->palette = from_ptrv(src->palette);
|
||||
inplace_SDL_Palette_to_64(dst->palette);
|
||||
}
|
||||
void inplace_SDL_PixelFormat_to_32(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_PixelFormat_t* src = a;
|
||||
my_SDL_PixelFormat_32_t* dst = a;
|
||||
inplace_SDL_Palette_to_32(src->palette);
|
||||
dst->palette = to_ptrv(src->palette);
|
||||
memmove(&dst->BitsPerPixel, &src->BitsPerPixel, sizeof(my_SDL_PixelFormat_32_t)-offsetof(my_SDL_PixelFormat_32_t, BitsPerPixel));
|
||||
}
|
||||
|
||||
void inplace_SDL_Surface_to_64(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_Surface_32_t* src = a;
|
||||
my_SDL_Surface_t* dst = a;
|
||||
dst->refcount = src->refcount;
|
||||
dst->format_version = src->format_version;
|
||||
dst->map = from_ptrv(src->map);
|
||||
dst->locked = src->locked;
|
||||
dst->unused1 = src->unused1;
|
||||
memmove(&dst->clip_rect, &src->clip_rect, sizeof(dst->clip_rect));
|
||||
dst->hwdata = from_ptrv(src->hwdata);
|
||||
dst->offset = src->offset;
|
||||
dst->pixels = from_ptrv(src->pixels);
|
||||
dst->pitch = src->pitch;
|
||||
dst->h = src->h;
|
||||
dst->w = src->w;
|
||||
dst->format = from_ptrv(src->format);
|
||||
inplace_SDL_PixelFormat_to_64(dst->format);
|
||||
}
|
||||
void inplace_SDL_Surface_to_32(void* a) {
|
||||
if(!a) return;
|
||||
my_SDL_Surface_t* src = a;
|
||||
my_SDL_Surface_32_t* dst = a;
|
||||
inplace_SDL_PixelFormat_to_32(src->format);
|
||||
dst->format = to_ptrv(src->format);
|
||||
dst->w = src->w;
|
||||
dst->h = src->h;
|
||||
dst->pitch = src->pitch;
|
||||
dst->pixels = to_ptrv(src->pixels);
|
||||
dst->offset = src->offset;
|
||||
dst->hwdata = to_ptrv(src->hwdata);
|
||||
memmove(&dst->clip_rect, &src->clip_rect, sizeof(dst->clip_rect));
|
||||
dst->unused1 = src->unused1;
|
||||
dst->locked = src->locked;
|
||||
dst->map = to_ptrv(src->map);
|
||||
dst->format_version = src->format_version;
|
||||
dst->refcount = src->refcount;
|
||||
}
|
||||
|
||||
|
||||
void convert_SDL_Event_to_32(void* dst_, const void* src_)
|
||||
{
|
||||
if(!src_|| !dst_) return;
|
||||
const my_SDL_Event_t *src = src_;
|
||||
my_SDL_Event_32_t* dst = dst_;
|
||||
dst->type = src->type;
|
||||
switch(src->type) {
|
||||
case SDL_ACTIVEEVENT:
|
||||
dst->active.gain = src->active.gain;
|
||||
dst->active.state = src->active.state;
|
||||
break;
|
||||
case SDL_KEYUP:
|
||||
case SDL_KEYDOWN:
|
||||
dst->key.keysym.mod = src->key.keysym.mod;
|
||||
dst->key.keysym.scancode = src->key.keysym.scancode;
|
||||
dst->key.keysym.sym = src->key.keysym.sym;
|
||||
dst->key.keysym.unicode = src->key.keysym.unicode;
|
||||
dst->key.state = src->key.state;
|
||||
dst->key.which = dst->key.which;
|
||||
break;
|
||||
case SDL_MOUSEMOTION:
|
||||
dst->motion.state = src->motion.state;
|
||||
dst->motion.which = src->motion.which;
|
||||
dst->motion.x = src->motion.x;
|
||||
dst->motion.y = src->motion.y;
|
||||
dst->motion.xrel = src->motion.xrel;
|
||||
dst->motion.yrel = src->motion.yrel;
|
||||
break;
|
||||
case SDL_MOUSEBUTTONUP:
|
||||
case SDL_MOUSEBUTTONDOWN:
|
||||
dst->button.button = src->button.button;
|
||||
dst->button.state = src->button.state;
|
||||
dst->button.which = src->button.which;
|
||||
dst->button.x = src->button.x;
|
||||
dst->button.y = src->button.y;
|
||||
break;
|
||||
case SDL_JOYAXISMOTION:
|
||||
dst->jaxis.axis = src->jaxis.axis;
|
||||
dst->jaxis.value = src->jaxis.value;
|
||||
dst->jaxis.which = src->jaxis.which;
|
||||
break;
|
||||
case SDL_JOYBALLMOTION:
|
||||
dst->jball.ball = src->jball.ball;
|
||||
dst->jball.which = src->jball.which;
|
||||
dst->jball.xrel = src->jball.xrel;
|
||||
dst->jball.yrel = src->jball.yrel;
|
||||
break;
|
||||
case SDL_JOYHATMOTION:
|
||||
dst->jhat.hat = src->jhat.hat;
|
||||
dst->jhat.value = src->jhat.value;
|
||||
dst->jhat.which = src->jhat.which;
|
||||
break;
|
||||
case SDL_JOYBUTTONUP:
|
||||
case SDL_JOYBUTTONDOWN:
|
||||
dst->jbutton.button = src->jbutton.button;
|
||||
dst->jbutton.state = src->jbutton.state;
|
||||
dst->jbutton.which = src->jbutton.which;
|
||||
break;
|
||||
case SDL_VIDEORESIZE:
|
||||
dst->resize.h = src->resize.h;
|
||||
dst->resize.w = src->resize.w;
|
||||
break;
|
||||
case SDL_VIDEOEXPOSE:
|
||||
case SDL_QUIT:
|
||||
break;
|
||||
case SDL_USEREVENT:
|
||||
dst->user.code = src->user.code;
|
||||
dst->user.data1 = to_ptrv(src->user.data1);
|
||||
dst->user.data2 = to_ptrv(src->user.data2);
|
||||
case SDL_SYSWMEVENT:
|
||||
printf_log(LOG_NONE, "TODO: Convert SDL_SYSWMEVENT\n");
|
||||
abort();
|
||||
break;
|
||||
default:
|
||||
printf_log(LOG_INFO, "Warning, unsuported SDL1.2 event %d\n", src->type);
|
||||
memcpy(dst, src, sizeof(my_SDL_Event_32_t));
|
||||
}
|
||||
}
|
@ -311,6 +311,18 @@ EXPORT int my32_pthread_rwlock_init(void* rdlock, void* attr)
|
||||
}
|
||||
EXPORT int my32___pthread_rwlock_init(void*, void*) __attribute__((alias("my32_pthread_rwlock_init")));
|
||||
|
||||
EXPORT int my32_pthread_rwlock_destroy(void* rdlock)
|
||||
{
|
||||
// the structure is bigger, but the "active" part should be the same size, so just save/restoore the padding at init
|
||||
uint8_t buff[sizeof(pthread_rwlock_t)];
|
||||
if(rdlock && sizeof(pthread_rwlock_t)>X86_RWLOCK_SIZE) {
|
||||
memcpy(buff, rdlock+32, sizeof(pthread_rwlock_t)-X86_RWLOCK_SIZE);
|
||||
}
|
||||
int ret = pthread_rwlock_destroy(rdlock);
|
||||
memcpy(rdlock+32, buff, sizeof(pthread_rwlock_t)-X86_RWLOCK_SIZE);
|
||||
return ret;
|
||||
}
|
||||
|
||||
EXPORT void my32___pthread_unwind_next(x64emu_t* emu, void* p)
|
||||
{
|
||||
emu->quit = 1;
|
||||
|
@ -1,6 +1,14 @@
|
||||
#() vFv -> vFv
|
||||
#() vFc -> vFc
|
||||
#() vFw -> vFw
|
||||
#() vFi -> vFi
|
||||
#() vFC -> vFC
|
||||
#() vFW -> vFW
|
||||
#() vFu -> vFu
|
||||
#() vFU -> vFU
|
||||
#() vFf -> vFf
|
||||
#() vFd -> vFd
|
||||
#() vFl -> vFl
|
||||
#() vFp -> vFp
|
||||
#() vFA -> vFA
|
||||
#() vFS -> vFS
|
||||
@ -17,16 +25,24 @@
|
||||
#() IFf -> IFf
|
||||
#() IFd -> IFd
|
||||
#() IFS -> IFS
|
||||
#() CFu -> CFu
|
||||
#() CFU -> CFU
|
||||
#() CFl -> CFl
|
||||
#() CFp -> CFp
|
||||
#() WFu -> WFu
|
||||
#() uFv -> uFv
|
||||
#() uFi -> uFi
|
||||
#() uFu -> uFu
|
||||
#() uFU -> uFU
|
||||
#() uFp -> uFp
|
||||
#() UFu -> UFu
|
||||
#() UFp -> UFp
|
||||
#() UFs -> UFs
|
||||
#() fFf -> fFf
|
||||
#() dFv -> dFv
|
||||
#() dFd -> dFd
|
||||
#() lFi -> lFi
|
||||
#() lFu -> lFu
|
||||
#() lFp -> lFp
|
||||
#() lFS -> lFS
|
||||
#() LFv -> LFv
|
||||
@ -46,6 +62,37 @@
|
||||
#() LFriiiiiiiiilt_ -> LFB
|
||||
#() vFEv -> vFEv
|
||||
#() vFEp -> vFEp
|
||||
#() vFcc -> vFcc
|
||||
#() vFww -> vFww
|
||||
#() vFii -> vFii
|
||||
#() vFiI -> vFiI
|
||||
#() vFiW -> vFiW
|
||||
#() vFiu -> vFiu
|
||||
#() vFiU -> vFiU
|
||||
#() vFif -> vFif
|
||||
#() vFid -> vFid
|
||||
#() vFip -> vFip
|
||||
#() vFWW -> vFWW
|
||||
#() vFuc -> vFuc
|
||||
#() vFuw -> vFuw
|
||||
#() vFui -> vFui
|
||||
#() vFuI -> vFuI
|
||||
#() vFuC -> vFuC
|
||||
#() vFuW -> vFuW
|
||||
#() vFuu -> vFuu
|
||||
#() vFuU -> vFuU
|
||||
#() vFuf -> vFuf
|
||||
#() vFud -> vFud
|
||||
#() vFul -> vFul
|
||||
#() vFup -> vFup
|
||||
#() vFUu -> vFUu
|
||||
#() vFfC -> vFfC
|
||||
#() vFff -> vFff
|
||||
#() vFdd -> vFdd
|
||||
#() vFlu -> vFlu
|
||||
#() vFlp -> vFlp
|
||||
#() vFpp -> vFpp
|
||||
#() wFpi -> wFpi
|
||||
#() iFEv -> iFEv
|
||||
#() iFEi -> iFEi
|
||||
#() iFEL -> iFEL
|
||||
@ -72,10 +119,19 @@
|
||||
#() iFhp -> iFhp
|
||||
#() iFhh -> iFhh
|
||||
#() IFII -> IFII
|
||||
#() CFip -> CFip
|
||||
#() CFuu -> CFuu
|
||||
#() CFuU -> CFuU
|
||||
#() CFpi -> CFpi
|
||||
#() uFEu -> uFEu
|
||||
#() uFEV -> uFEV
|
||||
#() uFuu -> uFuu
|
||||
#() uFup -> uFup
|
||||
#() uFpi -> uFpi
|
||||
#() uFpp -> uFpp
|
||||
#() uFpa -> uFpa
|
||||
#() UFii -> UFii
|
||||
#() UFuu -> UFuu
|
||||
#() UFUU -> UFUU
|
||||
#() UFss -> UFss
|
||||
#() fFif -> fFif
|
||||
@ -88,15 +144,19 @@
|
||||
#() dFdd -> dFdd
|
||||
#() dFdD -> dFdD
|
||||
#() dFdp -> dFdp
|
||||
#() lFui -> lFui
|
||||
#() LFpL -> LFpL
|
||||
#() LFpp -> LFpp
|
||||
#() pFEv -> pFEv
|
||||
#() pFEu -> pFEu
|
||||
#() pFEp -> pFEp
|
||||
#() pFES -> pFES
|
||||
#() pFiu -> pFiu
|
||||
#() pFia -> pFia
|
||||
#() pFuu -> pFuu
|
||||
#() pFLL -> pFLL
|
||||
#() pFpi -> pFpi
|
||||
#() pFpu -> pFpu
|
||||
#() pFpL -> pFpL
|
||||
#() pFpp -> pFpp
|
||||
#() SFpp -> SFpp
|
||||
@ -115,9 +175,65 @@
|
||||
#() vFEip -> vFEip
|
||||
#() vFEpi -> vFEpi
|
||||
#() vFEpu -> vFEpu
|
||||
#() vFEpp -> vFEpp
|
||||
#() vFccc -> vFccc
|
||||
#() vFwww -> vFwww
|
||||
#() vFiii -> vFiii
|
||||
#() vFiif -> vFiif
|
||||
#() vFiip -> vFiip
|
||||
#() vFiII -> vFiII
|
||||
#() vFiui -> vFiui
|
||||
#() vFiuu -> vFiuu
|
||||
#() vFiup -> vFiup
|
||||
#() vFiUU -> vFiUU
|
||||
#() vFiff -> vFiff
|
||||
#() vFidd -> vFidd
|
||||
#() vFilu -> vFilu
|
||||
#() vFill -> vFill
|
||||
#() vFilp -> vFilp
|
||||
#() vFipi -> vFipi
|
||||
#() vFipu -> vFipu
|
||||
#() vFipp -> vFipp
|
||||
#() vFCCC -> vFCCC
|
||||
#() vFWWW -> vFWWW
|
||||
#() vFucc -> vFucc
|
||||
#() vFuww -> vFuww
|
||||
#() vFuii -> vFuii
|
||||
#() vFuiI -> vFuiI
|
||||
#() vFuiu -> vFuiu
|
||||
#() vFuiU -> vFuiU
|
||||
#() vFuif -> vFuif
|
||||
#() vFuid -> vFuid
|
||||
#() vFuip -> vFuip
|
||||
#() vFuII -> vFuII
|
||||
#() vFuWW -> vFuWW
|
||||
#() vFuui -> vFuui
|
||||
#() vFuuC -> vFuuC
|
||||
#() vFuuu -> vFuuu
|
||||
#() vFuuU -> vFuuU
|
||||
#() vFuuf -> vFuuf
|
||||
#() vFuud -> vFuud
|
||||
#() vFuup -> vFuup
|
||||
#() vFuUU -> vFuUU
|
||||
#() vFuff -> vFuff
|
||||
#() vFudd -> vFudd
|
||||
#() vFull -> vFull
|
||||
#() vFulp -> vFulp
|
||||
#() vFupp -> vFupp
|
||||
#() vFfff -> vFfff
|
||||
#() vFfpp -> vFfpp
|
||||
#() vFddd -> vFddd
|
||||
#() vFdpp -> vFdpp
|
||||
#() vFlii -> vFlii
|
||||
#() vFlip -> vFlip
|
||||
#() vFllp -> vFllp
|
||||
#() vFlpp -> vFlpp
|
||||
#() vFpip -> vFpip
|
||||
#() vFpuU -> vFpuU
|
||||
#() vFplp -> vFplp
|
||||
#() vFppi -> vFppi
|
||||
#() vFppu -> vFppu
|
||||
#() vFppp -> vFppp
|
||||
#() iFEip -> iFEip
|
||||
#() iFEpi -> iFEpi
|
||||
#() iFEpL -> iFEpL
|
||||
@ -137,12 +253,18 @@
|
||||
#() iFipL -> iFipL
|
||||
#() iFipp -> iFipp
|
||||
#() iFuii -> iFuii
|
||||
#() iFuip -> iFuip
|
||||
#() iFuui -> iFuui
|
||||
#() iFuuu -> iFuuu
|
||||
#() iFuup -> iFuup
|
||||
#() iFuLp -> iFuLp
|
||||
#() iFfff -> iFfff
|
||||
#() iFpiu -> iFpiu
|
||||
#() iFpip -> iFpip
|
||||
#() iFpuC -> iFpuC
|
||||
#() iFpuu -> iFpuu
|
||||
#() iFpuU -> iFpuU
|
||||
#() iFpup -> iFpup
|
||||
#() iFpLi -> iFpLi
|
||||
#() iFppi -> iFppi
|
||||
#() iFppu -> iFppu
|
||||
@ -156,6 +278,17 @@
|
||||
#() iFSIi -> iFSIi
|
||||
#() iFSli -> iFSli
|
||||
#() IFiIi -> IFiIi
|
||||
#() CFipp -> CFipp
|
||||
#() CFuUu -> CFuUu
|
||||
#() CFuff -> CFuff
|
||||
#() uFilp -> uFilp
|
||||
#() uFipu -> uFipu
|
||||
#() uFuip -> uFuip
|
||||
#() uFuuu -> uFuuu
|
||||
#() uFuup -> uFuup
|
||||
#() uFupp -> uFupp
|
||||
#() uFpuU -> uFpuU
|
||||
#() fFuii -> fFuii
|
||||
#() fFfff -> fFfff
|
||||
#() fFffp -> fFffp
|
||||
#() fFppa -> fFppa
|
||||
@ -169,11 +302,16 @@
|
||||
#() pFEpi -> pFEpi
|
||||
#() pFEpp -> pFEpp
|
||||
#() pFipi -> pFipi
|
||||
#() pFulu -> pFulu
|
||||
#() pFpii -> pFpii
|
||||
#() pFpiL -> pFpiL
|
||||
#() pFpip -> pFpip
|
||||
#() pFpiS -> pFpiS
|
||||
#() pFpuL -> pFpuL
|
||||
#() pFpup -> pFpup
|
||||
#() pFppu -> pFppu
|
||||
#() pFppL -> pFppL
|
||||
#() pFppp -> pFppp
|
||||
#() pFpOM -> pFpOM
|
||||
#() aFipa -> aFipa
|
||||
#() SFEpp -> SFEpp
|
||||
@ -188,10 +326,87 @@
|
||||
#() lFpBp_i -> lFpBi
|
||||
#() LFpBp_i -> LFpBi
|
||||
#() pFppriiiiiiiiilt_ -> pFppB
|
||||
#() vFEipp -> vFEipp
|
||||
#() vFEipV -> vFEipV
|
||||
#() vFEpup -> vFEpup
|
||||
#() vFEppp -> vFEppp
|
||||
#() vFcccc -> vFcccc
|
||||
#() vFwwww -> vFwwww
|
||||
#() vFiiii -> vFiiii
|
||||
#() vFiiip -> vFiiip
|
||||
#() vFiiCp -> vFiiCp
|
||||
#() vFiill -> vFiill
|
||||
#() vFiIII -> vFiIII
|
||||
#() vFiuip -> vFiuip
|
||||
#() vFiuuu -> vFiuuu
|
||||
#() vFiulp -> vFiulp
|
||||
#() vFiUUU -> vFiUUU
|
||||
#() vFifff -> vFifff
|
||||
#() vFiddd -> vFiddd
|
||||
#() vFilip -> vFilip
|
||||
#() vFilpu -> vFilpu
|
||||
#() vFilpp -> vFilpp
|
||||
#() vFipup -> vFipup
|
||||
#() vFipll -> vFipll
|
||||
#() vFCCCC -> vFCCCC
|
||||
#() vFWWWW -> vFWWWW
|
||||
#() vFuccc -> vFuccc
|
||||
#() vFuwww -> vFuwww
|
||||
#() vFuiii -> vFuiii
|
||||
#() vFuiip -> vFuiip
|
||||
#() vFuiII -> vFuiII
|
||||
#() vFuiui -> vFuiui
|
||||
#() vFuiuC -> vFuiuC
|
||||
#() vFuiuu -> vFuiuu
|
||||
#() vFuiup -> vFuiup
|
||||
#() vFuiUU -> vFuiUU
|
||||
#() vFuifi -> vFuifi
|
||||
#() vFuiff -> vFuiff
|
||||
#() vFuidd -> vFuidd
|
||||
#() vFuilp -> vFuilp
|
||||
#() vFuipi -> vFuipi
|
||||
#() vFuipu -> vFuipu
|
||||
#() vFuipp -> vFuipp
|
||||
#() vFuIII -> vFuIII
|
||||
#() vFuWWW -> vFuWWW
|
||||
#() vFuuii -> vFuuii
|
||||
#() vFuuiu -> vFuuiu
|
||||
#() vFuuil -> vFuuil
|
||||
#() vFuuip -> vFuuip
|
||||
#() vFuuCu -> vFuuCu
|
||||
#() vFuuCp -> vFuuCp
|
||||
#() vFuuui -> vFuuui
|
||||
#() vFuuuu -> vFuuuu
|
||||
#() vFuuuf -> vFuuuf
|
||||
#() vFuuud -> vFuuud
|
||||
#() vFuuul -> vFuuul
|
||||
#() vFuuup -> vFuuup
|
||||
#() vFuuUl -> vFuuUl
|
||||
#() vFuuff -> vFuuff
|
||||
#() vFuuli -> vFuuli
|
||||
#() vFuupi -> vFuupi
|
||||
#() vFuupp -> vFuupp
|
||||
#() vFuUui -> vFuUui
|
||||
#() vFuUup -> vFuUup
|
||||
#() vFuUUU -> vFuUUU
|
||||
#() vFufff -> vFufff
|
||||
#() vFuddd -> vFuddd
|
||||
#() vFuluU -> vFuluU
|
||||
#() vFullC -> vFullC
|
||||
#() vFullp -> vFullp
|
||||
#() vFulpu -> vFulpu
|
||||
#() vFulpp -> vFulpp
|
||||
#() vFupii -> vFupii
|
||||
#() vFuppi -> vFuppi
|
||||
#() vFuppu -> vFuppu
|
||||
#() vFffff -> vFffff
|
||||
#() vFdddd -> vFdddd
|
||||
#() vFllii -> vFllii
|
||||
#() vFpiii -> vFpiii
|
||||
#() vFpipp -> vFpipp
|
||||
#() vFplpp -> vFplpp
|
||||
#() vFppip -> vFppip
|
||||
#() vFpppp -> vFpppp
|
||||
#() iFEiip -> iFEiip
|
||||
#() iFEiiN -> iFEiiN
|
||||
#() iFEipp -> iFEipp
|
||||
@ -213,18 +428,39 @@
|
||||
#() iFipii -> iFipii
|
||||
#() iFipup -> iFipup
|
||||
#() iFippi -> iFippi
|
||||
#() iFuiup -> iFuiup
|
||||
#() iFuupi -> iFuupi
|
||||
#() iFpiip -> iFpiip
|
||||
#() iFpipp -> iFpipp
|
||||
#() iFpuup -> iFpuup
|
||||
#() iFpupp -> iFpupp
|
||||
#() iFppii -> iFppii
|
||||
#() iFppiU -> iFppiU
|
||||
#() iFppip -> iFppip
|
||||
#() iFpppi -> iFpppi
|
||||
#() iFpppp -> iFpppp
|
||||
#() iFhpiL -> iFhpiL
|
||||
#() CFuuff -> CFuuff
|
||||
#() uFuuuu -> uFuuuu
|
||||
#() lFEipi -> lFEipi
|
||||
#() lFiipL -> lFiipL
|
||||
#() lFipLi -> lFipLi
|
||||
#() lFpuip -> lFpuip
|
||||
#() LFpLLS -> LFpLLS
|
||||
#() LFppLp -> LFppLp
|
||||
#() LFppLa -> LFppLa
|
||||
#() pFEppi -> pFEppi
|
||||
#() pFEppp -> pFEppp
|
||||
#() pFiiiu -> pFiiiu
|
||||
#() pFillu -> pFillu
|
||||
#() pFullu -> pFullu
|
||||
#() pFlfff -> pFlfff
|
||||
#() pFpiii -> pFpiii
|
||||
#() pFpiLL -> pFpiLL
|
||||
#() pFpipp -> pFpipp
|
||||
#() pFppLL -> pFppLL
|
||||
#() pFpppi -> pFpppi
|
||||
#() pFpppp -> pFpppp
|
||||
#() IFpBp_ii -> IFpBii
|
||||
#() UFpBp_ii -> UFpBii
|
||||
#() lFiibp_L -> lFiiBL
|
||||
@ -232,6 +468,92 @@
|
||||
#() iFEpprLL_ -> iFEppB
|
||||
#() LFpLpriiiiiiiiilt_ -> LFpLpB
|
||||
#() vFEpLLp -> vFEpLLp
|
||||
#() vFiiiii -> vFiiiii
|
||||
#() vFiiiiu -> vFiiiiu
|
||||
#() vFiiuii -> vFiiuii
|
||||
#() vFiiuup -> vFiiuup
|
||||
#() vFiillu -> vFiillu
|
||||
#() vFiilll -> vFiilll
|
||||
#() vFiipll -> vFiipll
|
||||
#() vFiIIII -> vFiIIII
|
||||
#() vFiuiip -> vFiuiip
|
||||
#() vFiuipi -> vFiuipi
|
||||
#() vFiuuuu -> vFiuuuu
|
||||
#() vFiulpp -> vFiulpp
|
||||
#() vFiUUUU -> vFiUUUU
|
||||
#() vFiffff -> vFiffff
|
||||
#() vFidddd -> vFidddd
|
||||
#() vFilill -> vFilill
|
||||
#() vFilipi -> vFilipi
|
||||
#() vFilipl -> vFilipl
|
||||
#() vFipipu -> vFipipu
|
||||
#() vFipipp -> vFipipp
|
||||
#() vFipupi -> vFipupi
|
||||
#() vFucccc -> vFucccc
|
||||
#() vFuwwww -> vFuwwww
|
||||
#() vFuiiii -> vFuiiii
|
||||
#() vFuiiiu -> vFuiiiu
|
||||
#() vFuiiip -> vFuiiip
|
||||
#() vFuiiCp -> vFuiiCp
|
||||
#() vFuiiup -> vFuiiup
|
||||
#() vFuiill -> vFuiill
|
||||
#() vFuiIII -> vFuiIII
|
||||
#() vFuiuii -> vFuiuii
|
||||
#() vFuiuip -> vFuiuip
|
||||
#() vFuiuCi -> vFuiuCi
|
||||
#() vFuiuCu -> vFuiuCu
|
||||
#() vFuiuuu -> vFuiuuu
|
||||
#() vFuiuup -> vFuiuup
|
||||
#() vFuiupi -> vFuiupi
|
||||
#() vFuiUUU -> vFuiUUU
|
||||
#() vFuifff -> vFuifff
|
||||
#() vFuiddd -> vFuiddd
|
||||
#() vFuipip -> vFuipip
|
||||
#() vFuipup -> vFuipup
|
||||
#() vFuippp -> vFuippp
|
||||
#() vFuIIII -> vFuIIII
|
||||
#() vFuCCCC -> vFuCCCC
|
||||
#() vFuCuip -> vFuCuip
|
||||
#() vFuCuup -> vFuCuup
|
||||
#() vFuWWWW -> vFuWWWW
|
||||
#() vFuuiii -> vFuuiii
|
||||
#() vFuuiip -> vFuuiip
|
||||
#() vFuuiui -> vFuuiui
|
||||
#() vFuuiuu -> vFuuiuu
|
||||
#() vFuuiup -> vFuuiup
|
||||
#() vFuuifi -> vFuuifi
|
||||
#() vFuuipC -> vFuuipC
|
||||
#() vFuuipu -> vFuuipu
|
||||
#() vFuuipp -> vFuuipp
|
||||
#() vFuuuii -> vFuuuii
|
||||
#() vFuuuiu -> vFuuuiu
|
||||
#() vFuuuil -> vFuuuil
|
||||
#() vFuuuip -> vFuuuip
|
||||
#() vFuuuui -> vFuuuui
|
||||
#() vFuuuuu -> vFuuuuu
|
||||
#() vFuuuup -> vFuuuup
|
||||
#() vFuuuli -> vFuuuli
|
||||
#() vFuuull -> vFuuull
|
||||
#() vFuulll -> vFuulll
|
||||
#() vFuullp -> vFuullp
|
||||
#() vFuupii -> vFuupii
|
||||
#() vFuuppu -> vFuuppu
|
||||
#() vFuUUUU -> vFuUUUU
|
||||
#() vFuffff -> vFuffff
|
||||
#() vFudddd -> vFudddd
|
||||
#() vFullpu -> vFullpu
|
||||
#() vFupiii -> vFupiii
|
||||
#() vFupupi -> vFupupi
|
||||
#() vFupupp -> vFupupp
|
||||
#() vFuplii -> vFuplii
|
||||
#() vFuppip -> vFuppip
|
||||
#() vFfffff -> vFfffff
|
||||
#() vFluipp -> vFluipp
|
||||
#() vFpilpp -> vFpilpp
|
||||
#() vFpuipp -> vFpuipp
|
||||
#() vFpppii -> vFpppii
|
||||
#() vFppppu -> vFppppu
|
||||
#() vFppppp -> vFppppp
|
||||
#() iFEiiip -> iFEiiip
|
||||
#() iFEipii -> iFEipii
|
||||
#() iFEpipp -> iFEpipp
|
||||
@ -245,24 +567,264 @@
|
||||
#() iFiiipp -> iFiiipp
|
||||
#() iFiLLLL -> iFiLLLL
|
||||
#() iFipLLi -> iFipLLi
|
||||
#() iFpiiip -> iFpiiip
|
||||
#() iFpippp -> iFpippp
|
||||
#() iFppipi -> iFppipi
|
||||
#() iFpppip -> iFpppip
|
||||
#() iFpppup -> iFpppup
|
||||
#() iFppppp -> iFppppp
|
||||
#() IFppIII -> IFppIII
|
||||
#() uFpLLLS -> uFpLLLS
|
||||
#() UFuiCiu -> UFuiCiu
|
||||
#() lFpuipC -> lFpuipC
|
||||
#() LFpLppa -> LFpLppa
|
||||
#() pFuiupp -> pFuiupp
|
||||
#() pFpippp -> pFpippp
|
||||
#() pFppipi -> pFppipi
|
||||
#() pFppuup -> pFppuup
|
||||
#() pFppupp -> pFppupp
|
||||
#() pFpppip -> pFpppip
|
||||
#() iFEBh_ppp -> iFEBppp
|
||||
#() LFpbp_LLp -> LFpBLLp
|
||||
#() LFpBp_LLp -> LFpBLLp
|
||||
#() iFippprLL_ -> iFipppB
|
||||
#() LFLbp_bL_Bp_BL_ -> LFLBBBB
|
||||
#() LFpLpriiiiiiiiilt_a -> LFpLpBa
|
||||
#() vFiiiiii -> vFiiiiii
|
||||
#() vFiiiuil -> vFiiiuil
|
||||
#() vFiiilpi -> vFiiilpi
|
||||
#() vFiiuilp -> vFiiuilp
|
||||
#() vFiffiff -> vFiffiff
|
||||
#() vFiddidd -> vFiddidd
|
||||
#() vFilipli -> vFilipli
|
||||
#() vFiliplu -> vFiliplu
|
||||
#() vFipiplp -> vFipiplp
|
||||
#() vFCCCCff -> vFCCCCff
|
||||
#() vFuiiiii -> vFuiiiii
|
||||
#() vFuiiuii -> vFuiiuii
|
||||
#() vFuiiuup -> vFuiiuup
|
||||
#() vFuiIIII -> vFuiIIII
|
||||
#() vFuiuiii -> vFuiuiii
|
||||
#() vFuiuiiC -> vFuiuiiC
|
||||
#() vFuiuiil -> vFuiuiil
|
||||
#() vFuiuiuu -> vFuiuiuu
|
||||
#() vFuiuiuU -> vFuiuiuU
|
||||
#() vFuiuCip -> vFuiuCip
|
||||
#() vFuiuuip -> vFuiuuip
|
||||
#() vFuiuuuu -> vFuiuuuu
|
||||
#() vFuiupii -> vFuiupii
|
||||
#() vFuiupiu -> vFuiupiu
|
||||
#() vFuiUUUU -> vFuiUUUU
|
||||
#() vFuiffff -> vFuiffff
|
||||
#() vFuidddd -> vFuidddd
|
||||
#() vFuipiup -> vFuipiup
|
||||
#() vFuCuuip -> vFuCuuip
|
||||
#() vFuuiiii -> vFuuiiii
|
||||
#() vFuuiuii -> vFuuiuii
|
||||
#() vFuuiuil -> vFuuiuil
|
||||
#() vFuuiuip -> vFuuiuip
|
||||
#() vFuuiuCu -> vFuuiuCu
|
||||
#() vFuuiuup -> vFuuiuup
|
||||
#() vFuuippp -> vFuuippp
|
||||
#() vFuuuiii -> vFuuuiii
|
||||
#() vFuuuiup -> vFuuuiup
|
||||
#() vFuuuipC -> vFuuuipC
|
||||
#() vFuuuipp -> vFuuuipp
|
||||
#() vFuuuuii -> vFuuuuii
|
||||
#() vFuuuuip -> vFuuuuip
|
||||
#() vFuuuuuu -> vFuuuuuu
|
||||
#() vFuuuull -> vFuuuull
|
||||
#() vFuuuppi -> vFuuuppi
|
||||
#() vFuuuppp -> vFuuuppp
|
||||
#() vFuuffff -> vFuuffff
|
||||
#() vFuudddd -> vFuudddd
|
||||
#() vFuupiii -> vFuupiii
|
||||
#() vFuupupp -> vFuupupp
|
||||
#() vFuuplii -> vFuuplii
|
||||
#() vFuffiip -> vFuffiip
|
||||
#() vFufffff -> vFufffff
|
||||
#() vFuddiip -> vFuddiip
|
||||
#() vFulluUC -> vFulluUC
|
||||
#() vFupiiii -> vFupiiii
|
||||
#() vFupupip -> vFupupip
|
||||
#() vFuppppu -> vFuppppu
|
||||
#() vFffffff -> vFffffff
|
||||
#() vFdddddd -> vFdddddd
|
||||
#() vFppiiii -> vFppiiii
|
||||
#() vFppupii -> vFppupii
|
||||
#() iFEpLppp -> iFEpLppp
|
||||
#() iFpiiipp -> iFpiiipp
|
||||
#() iFpiippp -> iFpiippp
|
||||
#() iFppiiii -> iFppiiii
|
||||
#() iFppIppp -> iFppIppp
|
||||
#() uFupuufp -> uFupuufp
|
||||
#() lFipLipu -> lFipLipu
|
||||
#() lFipLipp -> lFipLipp
|
||||
#() pFEpLLiN -> pFEpLLiN
|
||||
#() pFpippip -> pFpippip
|
||||
#() vFiiiiiip -> vFiiiiiip
|
||||
#() vFiiiiuup -> vFiiiiuup
|
||||
#() vFiiuilil -> vFiiuilil
|
||||
#() vFiiffffp -> vFiiffffp
|
||||
#() vFiuulipi -> vFiuulipi
|
||||
#() vFiupuuup -> vFiupuuup
|
||||
#() vFilipliu -> vFilipliu
|
||||
#() vFilulipi -> vFilulipi
|
||||
#() vFCCCCfff -> vFCCCCfff
|
||||
#() vFuiiiiii -> vFuiiiiii
|
||||
#() vFuiiiiiC -> vFuiiiiiC
|
||||
#() vFuiiiuip -> vFuiiiuip
|
||||
#() vFuiiiuup -> vFuiiiuup
|
||||
#() vFuiuiiii -> vFuiuiiii
|
||||
#() vFuiuiiiC -> vFuiuiiiC
|
||||
#() vFuiuiiip -> vFuiuiiip
|
||||
#() vFuiuiiuU -> vFuiuiiuU
|
||||
#() vFuiuCiuu -> vFuiuCiuu
|
||||
#() vFuiupiiu -> vFuiupiiu
|
||||
#() vFuiupuip -> vFuiupuip
|
||||
#() vFuipiiii -> vFuipiiii
|
||||
#() vFuipffff -> vFuipffff
|
||||
#() vFuipdddd -> vFuipdddd
|
||||
#() vFuuiiiii -> vFuuiiiii
|
||||
#() vFuuiiiiC -> vFuuiiiiC
|
||||
#() vFuuiiiiu -> vFuuiiiiu
|
||||
#() vFuuiiuup -> vFuuiiuup
|
||||
#() vFuuiCiui -> vFuuiCiui
|
||||
#() vFuuiCiuu -> vFuuiCiuu
|
||||
#() vFuuiuiii -> vFuuiuiii
|
||||
#() vFuuiuiiC -> vFuuiuiiC
|
||||
#() vFuuipppp -> vFuuipppp
|
||||
#() vFuuuiiii -> vFuuuiiii
|
||||
#() vFuuuiiCp -> vFuuuiiCp
|
||||
#() vFuuuiuil -> vFuuuiuil
|
||||
#() vFuuuiupi -> vFuuuiupi
|
||||
#() vFuuuuuuu -> vFuuuuuuu
|
||||
#() vFuuuulll -> vFuuuulll
|
||||
#() vFuuuffff -> vFuuuffff
|
||||
#() vFuuudddd -> vFuuudddd
|
||||
#() vFuuffiip -> vFuuffiip
|
||||
#() vFuuddiip -> vFuuddiip
|
||||
#() vFuulluup -> vFuulluup
|
||||
#() vFuupiiii -> vFuupiiii
|
||||
#() vFuuppppu -> vFuuppppu
|
||||
#() vFuuppppp -> vFuuppppp
|
||||
#() vFuffffff -> vFuffffff
|
||||
#() vFudddddd -> vFudddddd
|
||||
#() vFlliiiip -> vFlliiiip
|
||||
#() iFEpLiipV -> iFEpLiipV
|
||||
#() iFpupLpLi -> iFpupLpLi
|
||||
#() uFuippppp -> uFuippppp
|
||||
#() pFEpLiiii -> pFEpLiiii
|
||||
#() pFEpLiiiI -> pFEpLiiiI
|
||||
#() vFiiiiuuip -> vFiiiiuuip
|
||||
#() vFiilliilp -> vFiilliilp
|
||||
#() vFiupuiuup -> vFiupuiuup
|
||||
#() vFiupuuuup -> vFiupuuuup
|
||||
#() vFuiiiiiii -> vFuiiiiiii
|
||||
#() vFuiiiiiiC -> vFuiiiiiiC
|
||||
#() vFuiiiiuup -> vFuiiiiuup
|
||||
#() vFuiiipiup -> vFuiiipiup
|
||||
#() vFuiuiiiii -> vFuiuiiiii
|
||||
#() vFuiuiiiip -> vFuiuiiiip
|
||||
#() vFuiuiiiuU -> vFuiuiiiuU
|
||||
#() vFuiuiiCuU -> vFuiuiiCuU
|
||||
#() vFuiuiuuuu -> vFuiuiuuuu
|
||||
#() vFuCCCCfff -> vFuCCCCfff
|
||||
#() vFuuiiiiiC -> vFuuiiiiiC
|
||||
#() vFuuiiiuip -> vFuuiiiuip
|
||||
#() vFuuiiiuup -> vFuuiiiuup
|
||||
#() vFuuiiuupp -> vFuuiiuupp
|
||||
#() vFuuiuiiii -> vFuuiuiiii
|
||||
#() vFuuiuiiiC -> vFuuiuiiiC
|
||||
#() vFuuiuiiip -> vFuuiuiiip
|
||||
#() vFuuuiiiiu -> vFuuuiiiiu
|
||||
#() vFuuuiuCil -> vFuuuiuCil
|
||||
#() vFuuuipipp -> vFuuuipipp
|
||||
#() vFuuuuuuuu -> vFuuuuuuuu
|
||||
#() vFuuufffff -> vFuuufffff
|
||||
#() vFffffffff -> vFffffffff
|
||||
#() iFEpippppp -> iFEpippppp
|
||||
#() iFppIIIppp -> iFppIIIppp
|
||||
#() CFuiifpppp -> CFuiifpppp
|
||||
#() uFuipppppp -> uFuipppppp
|
||||
#() uFuupuuiuf -> uFuupuuiuf
|
||||
#() uFulpppppp -> uFulpppppp
|
||||
#() vFiiiiiiiii -> vFiiiiiiiii
|
||||
#() vFiiiiiiill -> vFiiiiiiill
|
||||
#() vFiiiiillli -> vFiiiiillli
|
||||
#() vFiiilllilp -> vFiiilllilp
|
||||
#() vFiupuiuuup -> vFiupuiuuup
|
||||
#() vFiupuuuuup -> vFiupuuuuup
|
||||
#() vFuiiiiiiii -> vFuiiiiiiii
|
||||
#() vFuiiiiiiiC -> vFuiiiiiiiC
|
||||
#() vFuiiiiiuip -> vFuiiiiiuip
|
||||
#() vFuiiiiiuup -> vFuiiiiiuup
|
||||
#() vFuiuiiiiip -> vFuiuiiiiip
|
||||
#() vFuiuiiiCuU -> vFuiuiiiCuU
|
||||
#() vFuiupuffup -> vFuiupuffup
|
||||
#() vFuuiiiiiii -> vFuuiiiiiii
|
||||
#() vFuuiiiiiiC -> vFuuiiiiiiC
|
||||
#() vFuuiiiiuup -> vFuuiiiiuup
|
||||
#() vFuuiuiiiii -> vFuuiuiiiii
|
||||
#() vFuuiuiiiip -> vFuuiuiiiip
|
||||
#() vFuuuiiiiCp -> vFuuuiiiiCp
|
||||
#() vFuuuuuuuuu -> vFuuuuuuuuu
|
||||
#() vFuupuuiuuf -> vFuupuuiuuf
|
||||
#() vFuffffffff -> vFuffffffff
|
||||
#() vFffCCCCfff -> vFffCCCCfff
|
||||
#() uFuulpiuiuf -> uFuulpiuiuf
|
||||
#() vFiiiiiiiiii -> vFiiiiiiiiii
|
||||
#() vFiiiiiiiiui -> vFiiiiiiiiui
|
||||
#() vFiiiiiiiiuu -> vFiiiiiiiiuu
|
||||
#() vFiiillliiip -> vFiiillliiip
|
||||
#() vFuiiiiiiiii -> vFuiiiiiiiii
|
||||
#() vFuiiiiiiiip -> vFuiiiiiiiip
|
||||
#() vFuiiiiiiuup -> vFuiiiiiiuup
|
||||
#() vFuiuiiiiuup -> vFuiuiiiiuup
|
||||
#() vFuuiiiiiiii -> vFuuiiiiiiii
|
||||
#() vFuuiiiiiuip -> vFuuiiiiiuip
|
||||
#() vFuuiiiiiuup -> vFuuiiiiiuup
|
||||
#() vFuuiuiiiiip -> vFuuiuiiiiip
|
||||
#() vFuuuuuuuCCC -> vFuuuuuuuCCC
|
||||
#() vFuuuuuuuuuu -> vFuuuuuuuuuu
|
||||
#() vFuupuiupuuf -> vFuupuiupuuf
|
||||
#() vFuffiiffiip -> vFuffiiffiip
|
||||
#() vFuddiiddiip -> vFuddiiddiip
|
||||
#() vFffffffffff -> vFffffffffff
|
||||
#() vFiiiiillliip -> vFiiiiillliip
|
||||
#() vFiiiiilllilp -> vFiiiiilllilp
|
||||
#() vFuiiiiiiiuip -> vFuiiiiiiiuip
|
||||
#() vFuiiiiiiiuup -> vFuiiiiiiiuup
|
||||
#() vFuiiiillliip -> vFuiiiillliip
|
||||
#() vFuiuiiiiiuup -> vFuiuiiiiiuup
|
||||
#() vFuuiiiiiiuup -> vFuuiiiiiiuup
|
||||
#() vFuuupupppppp -> vFuuupupppppp
|
||||
#() vFuuffiiffiip -> vFuuffiiffiip
|
||||
#() vFuufffffffff -> vFuufffffffff
|
||||
#() vFuuddiiddiip -> vFuuddiiddiip
|
||||
#() vFuUuuuuuuuuu -> vFuUuuuuuuuuu
|
||||
#() vFuffffffffff -> vFuffffffffff
|
||||
#() vFUufffffffff -> vFUufffffffff
|
||||
#() vFuiiiiiiiiuUC -> vFuiiiiiiiiuUC
|
||||
#() vFuiiiiiiiuuip -> vFuiiiiiiiuuip
|
||||
#() vFuuiiiiiiiiuu -> vFuuiiiiiiiiuu
|
||||
#() vFuuiiiiiiiuip -> vFuuiiiiiiiuip
|
||||
#() vFuuiiiiiiiuup -> vFuuiiiiiiiuup
|
||||
#() vFuuuuuuuuuuuu -> vFuuuuuuuuuuuu
|
||||
#() vFffffffffffff -> vFffffffffffff
|
||||
#() vFuiiiiiiiiiuup -> vFuiiiiiiiiiuup
|
||||
#() vFuuuuuuuuuuuuu -> vFuuuuuuuuuuuuu
|
||||
#() vFuUuuuuuuuuuuu -> vFuUuuuuuuuuuuu
|
||||
#() vFuffffffffffff -> vFuffffffffffff
|
||||
#() uFippuuuulllipp -> uFippuuuulllipp
|
||||
#() vFuffiiffiiffiip -> vFuffiiffiiffiip
|
||||
#() vFuddiiddiiddiip -> vFuddiiddiiddiip
|
||||
#() vFuiiiiiuiiiiilll -> vFuiiiiiuiiiiilll
|
||||
#() vFuuiiiiuuiiiiiii -> vFuuiiiiuuiiiiiii
|
||||
#() vFfffffffffffffff -> vFfffffffffffffff
|
||||
#() vFuuuuiiiiuuiiiiiii -> vFuuuuiiiiuuiiiiiii
|
||||
#() vFppuiiiiipuiiiiiiii -> vFppuiiiiipuiiiiiiii
|
||||
#() uFippuuuuiiiiuuiiiiiiiipp -> uFippuuuuiiiiuuiiiiiiiipp
|
||||
#defined(ANDROID) vFEpppp -> vFEpppp
|
||||
#defined(HAVE_LD80BITS) DFD -> DFD
|
||||
#defined(HAVE_LD80BITS) DFDD -> DFDD
|
||||
@ -426,6 +988,26 @@ wrappedlibdl:
|
||||
- dlvsym
|
||||
- iFpppi:
|
||||
- dladdr1
|
||||
wrappedlibgl:
|
||||
- iFi:
|
||||
- glXSwapIntervalMESA
|
||||
- pFp:
|
||||
- glGetVkProcAddrNV
|
||||
- glXGetProcAddress
|
||||
- glXGetProcAddressARB
|
||||
- vFpp:
|
||||
- glDebugMessageCallback
|
||||
- glDebugMessageCallbackAMD
|
||||
- glDebugMessageCallbackARB
|
||||
- glDebugMessageCallbackKHR
|
||||
- iFpp:
|
||||
- eglDebugMessageControlKHR
|
||||
- vFipp:
|
||||
- glProgramCallbackMESA
|
||||
- vFppi:
|
||||
- glXSwapIntervalEXT
|
||||
- vFppp:
|
||||
- eglSetBlobCacheFuncsANDROID
|
||||
wrappedlibm:
|
||||
- UFs:
|
||||
- cacosf
|
||||
@ -526,7 +1108,7 @@ wrappedlibpthread:
|
||||
- pthread_mutex_trylock
|
||||
- pthread_mutex_unlock
|
||||
- pthread_mutexattr_init
|
||||
- pthread_rwlock_rdlock
|
||||
- pthread_rwlock_destroy
|
||||
- pthread_rwlock_unlock
|
||||
- pthread_rwlock_wrlock
|
||||
- iFh:
|
||||
@ -589,3 +1171,32 @@ wrappedlibpthread:
|
||||
- iFhppp:
|
||||
- pthread_create
|
||||
wrappedlibrt:
|
||||
wrappedsdl1:
|
||||
- vFv:
|
||||
- SDL_Quit
|
||||
- vFp:
|
||||
- SDL_KillThread
|
||||
- SDL_UnlockSurface
|
||||
- iFv:
|
||||
- SDL_Has3DNow
|
||||
- SDL_Has3DNowExt
|
||||
- SDL_HasAltiVec
|
||||
- SDL_HasMMX
|
||||
- SDL_HasMMXExt
|
||||
- SDL_HasRDTSC
|
||||
- SDL_HasSSE
|
||||
- SDL_HasSSE2
|
||||
- iFp:
|
||||
- SDL_Flip
|
||||
- SDL_LockSurface
|
||||
- SDL_PollEvent
|
||||
- pFp:
|
||||
- SDL_GL_GetProcAddress
|
||||
- SDL_LoadObject
|
||||
- iFpp:
|
||||
- SDL_OpenAudio
|
||||
- pFpp:
|
||||
- SDL_CreateThread
|
||||
- SDL_LoadFunction
|
||||
- pFiiiu:
|
||||
- SDL_SetVideoMode
|
||||
|
8
src/wrapped32/generated/wrappedlibgldefs32.h
Normal file
8
src/wrapped32/generated/wrappedlibgldefs32.h
Normal file
@ -0,0 +1,8 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedlibglDEFS32_H_
|
||||
#define __wrappedlibglDEFS32_H_
|
||||
|
||||
|
||||
#endif // __wrappedlibglDEFS32_H_
|
36
src/wrapped32/generated/wrappedlibgltypes32.h
Normal file
36
src/wrapped32/generated/wrappedlibgltypes32.h
Normal file
@ -0,0 +1,36 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedlibglTYPES32_H_
|
||||
#define __wrappedlibglTYPES32_H_
|
||||
|
||||
#ifndef LIBNAME
|
||||
#error You should only #include this file inside a wrapped*.c file
|
||||
#endif
|
||||
#ifndef ADDED_FUNCTIONS
|
||||
#define ADDED_FUNCTIONS()
|
||||
#endif
|
||||
|
||||
typedef int32_t (*iFi_t)(int32_t);
|
||||
typedef void* (*pFp_t)(void*);
|
||||
typedef void (*vFpp_t)(void*, void*);
|
||||
typedef int32_t (*iFpp_t)(void*, void*);
|
||||
typedef void (*vFipp_t)(int32_t, void*, void*);
|
||||
typedef void (*vFppi_t)(void*, void*, int32_t);
|
||||
typedef void (*vFppp_t)(void*, void*, void*);
|
||||
|
||||
#define SUPER() ADDED_FUNCTIONS() \
|
||||
GO(glXSwapIntervalMESA, iFi_t) \
|
||||
GO(glGetVkProcAddrNV, pFp_t) \
|
||||
GO(glXGetProcAddress, pFp_t) \
|
||||
GO(glXGetProcAddressARB, pFp_t) \
|
||||
GO(glDebugMessageCallback, vFpp_t) \
|
||||
GO(glDebugMessageCallbackAMD, vFpp_t) \
|
||||
GO(glDebugMessageCallbackARB, vFpp_t) \
|
||||
GO(glDebugMessageCallbackKHR, vFpp_t) \
|
||||
GO(eglDebugMessageControlKHR, iFpp_t) \
|
||||
GO(glProgramCallbackMESA, vFipp_t) \
|
||||
GO(glXSwapIntervalEXT, vFppi_t) \
|
||||
GO(eglSetBlobCacheFuncsANDROID, vFppp_t)
|
||||
|
||||
#endif // __wrappedlibglTYPES32_H_
|
8
src/wrapped32/generated/wrappedlibglundefs32.h
Normal file
8
src/wrapped32/generated/wrappedlibglundefs32.h
Normal file
@ -0,0 +1,8 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedlibglUNDEFS32_H_
|
||||
#define __wrappedlibglUNDEFS32_H_
|
||||
|
||||
|
||||
#endif // __wrappedlibglUNDEFS32_H_
|
@ -51,7 +51,7 @@ typedef int32_t (*iFhppp_t)(uintptr_t, void*, void*, void*);
|
||||
GO(pthread_mutex_trylock, iFp_t) \
|
||||
GO(pthread_mutex_unlock, iFp_t) \
|
||||
GO(pthread_mutexattr_init, iFp_t) \
|
||||
GO(pthread_rwlock_rdlock, iFp_t) \
|
||||
GO(pthread_rwlock_destroy, iFp_t) \
|
||||
GO(pthread_rwlock_unlock, iFp_t) \
|
||||
GO(pthread_rwlock_wrlock, iFp_t) \
|
||||
GO(pthread_detach, iFh_t) \
|
||||
|
8
src/wrapped32/generated/wrappedsdl1defs32.h
Normal file
8
src/wrapped32/generated/wrappedsdl1defs32.h
Normal file
@ -0,0 +1,8 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedsdl1DEFS32_H_
|
||||
#define __wrappedsdl1DEFS32_H_
|
||||
|
||||
|
||||
#endif // __wrappedsdl1DEFS32_H_
|
45
src/wrapped32/generated/wrappedsdl1types32.h
Normal file
45
src/wrapped32/generated/wrappedsdl1types32.h
Normal file
@ -0,0 +1,45 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedsdl1TYPES32_H_
|
||||
#define __wrappedsdl1TYPES32_H_
|
||||
|
||||
#ifndef LIBNAME
|
||||
#error You should only #include this file inside a wrapped*.c file
|
||||
#endif
|
||||
#ifndef ADDED_FUNCTIONS
|
||||
#define ADDED_FUNCTIONS()
|
||||
#endif
|
||||
|
||||
typedef void (*vFv_t)(void);
|
||||
typedef void (*vFp_t)(void*);
|
||||
typedef int32_t (*iFv_t)(void);
|
||||
typedef int32_t (*iFp_t)(void*);
|
||||
typedef void* (*pFp_t)(void*);
|
||||
typedef int32_t (*iFpp_t)(void*, void*);
|
||||
typedef void* (*pFpp_t)(void*, void*);
|
||||
typedef void* (*pFiiiu_t)(int32_t, int32_t, int32_t, uint32_t);
|
||||
|
||||
#define SUPER() ADDED_FUNCTIONS() \
|
||||
GO(SDL_Quit, vFv_t) \
|
||||
GO(SDL_KillThread, vFp_t) \
|
||||
GO(SDL_UnlockSurface, vFp_t) \
|
||||
GO(SDL_Has3DNow, iFv_t) \
|
||||
GO(SDL_Has3DNowExt, iFv_t) \
|
||||
GO(SDL_HasAltiVec, iFv_t) \
|
||||
GO(SDL_HasMMX, iFv_t) \
|
||||
GO(SDL_HasMMXExt, iFv_t) \
|
||||
GO(SDL_HasRDTSC, iFv_t) \
|
||||
GO(SDL_HasSSE, iFv_t) \
|
||||
GO(SDL_HasSSE2, iFv_t) \
|
||||
GO(SDL_Flip, iFp_t) \
|
||||
GO(SDL_LockSurface, iFp_t) \
|
||||
GO(SDL_PollEvent, iFp_t) \
|
||||
GO(SDL_GL_GetProcAddress, pFp_t) \
|
||||
GO(SDL_LoadObject, pFp_t) \
|
||||
GO(SDL_OpenAudio, iFpp_t) \
|
||||
GO(SDL_CreateThread, pFpp_t) \
|
||||
GO(SDL_LoadFunction, pFpp_t) \
|
||||
GO(SDL_SetVideoMode, pFiiiu_t)
|
||||
|
||||
#endif // __wrappedsdl1TYPES32_H_
|
8
src/wrapped32/generated/wrappedsdl1undefs32.h
Normal file
8
src/wrapped32/generated/wrappedsdl1undefs32.h
Normal file
@ -0,0 +1,8 @@
|
||||
/******************************************************************
|
||||
* File automatically generated by rebuild_wrappers_32.py (v0.0.1.1) *
|
||||
******************************************************************/
|
||||
#ifndef __wrappedsdl1UNDEFS32_H_
|
||||
#define __wrappedsdl1UNDEFS32_H_
|
||||
|
||||
|
||||
#endif // __wrappedsdl1UNDEFS32_H_
|
File diff suppressed because it is too large
Load Diff
@ -39,8 +39,16 @@ typedef void (*wrapper_t)(x64emu_t* emu, uintptr_t fnc);
|
||||
// t = char* as a return value (copies to a lower address if the return address is too high)
|
||||
|
||||
void vFv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFw_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFl_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFA_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -57,16 +65,24 @@ void iFS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFl_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void WFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFs_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void dFv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void dFd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -86,6 +102,37 @@ void pFrL__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFriiiiiiiiilt__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFcc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiI_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFif_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFid_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuw_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuI_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFud_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFul_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFUu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFfC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFdd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void wFpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -112,10 +159,19 @@ void iFhi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFhp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFhh_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFEu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFEV_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFpa_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFss_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFif_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -128,15 +184,19 @@ void dFdi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void dFdd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void dFdD_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void dFdp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEv_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFES_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFia_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFLL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void SFpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -155,9 +215,65 @@ void pFriiiiiiiiilt_p_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEpu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFccc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFwww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiif_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFidd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFill_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFCCC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFWWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFucc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiI_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuif_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuid_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuud_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFudd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFull_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFulp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFfpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFdpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFllp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFplp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -177,12 +293,18 @@ void iFipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFipL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuLp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpuC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpLi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -196,6 +318,17 @@ void iFhpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFSIi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFSli_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFiIi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuUu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFpuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFffp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void fFppa_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -209,11 +342,16 @@ void pFEip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFulu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpiL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpiS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpuL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpOM_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void aFipa_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void SFEpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -228,10 +366,87 @@ void dFpBp_a_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFpBp_i_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpBp_i_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppriiiiiiiiilt__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEipV_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEpup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFcccc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFwwww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiCp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiill_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiulp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFifff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilpu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFCCCC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFWWWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuccc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuwww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuifi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuidd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuWWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuCu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuCp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuud_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuul_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuUl_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuli_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFufff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuluU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFullC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFullp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFulpu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFulpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFdddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFllii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFplpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEiiN_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -253,18 +468,39 @@ void iFiuui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFipii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFipup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFippi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFuupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppiU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFhpiL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuuff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFEipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFiipL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFipLi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFpuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpLLS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFppLp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFppLa_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFiiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFillu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFullu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFlfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpiLL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppLL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFpBp_ii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFpBp_ii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFiibp_L_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -272,6 +508,92 @@ void LFpbp_Lp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpprLL__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpLpriiiiiiiiilt__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFEpLLp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiillu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiilll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiipll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiIIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiulpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiUUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFidddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilill_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilipl_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFucccc_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuwwww_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiCp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiill_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuCi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuCu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuifff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuippp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuIIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuCCCC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuCuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuCuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuWWWW_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuifi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuipC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuli_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuull_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuulll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuullp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFudddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFullpu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuplii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuppip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFfffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFluipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpilpp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpuipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFpppii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEipii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
@ -285,24 +607,264 @@ void iFiiipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFiiipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFiLLLL_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFipLLi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpippp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpppip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpppup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void IFppIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFpLLLS_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void UFuiCiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFpuipC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpLppa_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFuiupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpippp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFppupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpppip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEBh_ppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpbp_LLp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpBp_LLp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFippprLL__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFLbp_bL_Bp_BL__32(x64emu_t *emu, uintptr_t fnc);
|
||||
void LFpLpriiiiiiiiilt_a_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiuil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiilpi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiuilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiffiff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiddidd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilipli_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiliplu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFipiplp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFCCCCff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiIIII_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuCip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiUUUU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuidddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuCuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuCu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuippp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuipC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuull_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuppi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuudddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuplii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFufffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuddiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFulluUC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFupupip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuppppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFdddddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppupii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpLppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpiiipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpiippp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppIppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFupuufp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFipLipu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void lFipLipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEpLLiN_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFpippip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiuilil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiffffp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiuulipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiupuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilipliu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFilulipi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFCCCCfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuCiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuipdddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiCiui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiCiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuipppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiiCp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiuil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiupi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuulll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuudddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuffiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuddiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuulluup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuppppu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFudddddd_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFlliiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpLiipV_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFpupLpLi_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuippppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEpLiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void pFEpLiiiI_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiilliilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiupuiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiupuuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiipiup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiCuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuCCCCfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiuupp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiiiiu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiuCil_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuipipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuufffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFEpippppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void iFppIIIppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void CFuiifpppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuipppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuupuuiuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFulpppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiiill_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiillli_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiilllilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiupuiuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiupuuuuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiCuU_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiupuffup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuiiiiCp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupuuiuuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffCCCCfff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFuulpiuiuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiiiiui_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiiiiiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiillliiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiuiiiiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuCCC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuupuiupuuf_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffiiffiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuddiiddiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiillliip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFiiiiilllilp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiillliip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiuiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuupupppppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuffiiffiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuufffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuddiiddiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFUufffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiiuUC_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiuuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiiiuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiiuip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFffffffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiiiiiuup_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuUuuuuuuuuuuu_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffffffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFippuuuulllipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuffiiffiiffiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuddiiddiiddiip_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuiiiiiuiiiiilll_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuiiiiuuiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFfffffffffffffff_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFuuuuiiiiuuiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void vFppuiiiiipuiiiiiiii_32(x64emu_t *emu, uintptr_t fnc);
|
||||
void uFippuuuuiiiiuuiiiiiiiipp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
|
||||
#if defined(ANDROID)
|
||||
void vFEpppp_32(x64emu_t *emu, uintptr_t fnc);
|
||||
|
562
src/wrapped32/wrappedlibgl.c
Normal file
562
src/wrapped32/wrappedlibgl.c
Normal file
@ -0,0 +1,562 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#define _GNU_SOURCE /* See feature_test_macros(7) */
|
||||
#include <dlfcn.h>
|
||||
|
||||
#include "wrappedlibs.h"
|
||||
|
||||
#include "debug.h"
|
||||
#include "wrapper32.h"
|
||||
#include "bridge.h"
|
||||
#include "librarian/library_private.h"
|
||||
#include "x64emu.h"
|
||||
#include "emu/x64emu_private.h"
|
||||
#include "box32context.h"
|
||||
#include "librarian.h"
|
||||
#include "callback.h"
|
||||
#include "gltools.h"
|
||||
|
||||
extern const char* libglName;
|
||||
#define LIBNAME libgl
|
||||
static library_t* my_lib = NULL;
|
||||
|
||||
// FIXME: old wrapped* type of file, cannot use generated/wrappedlibgltypes.h
|
||||
void* getGLProcAddress32(x64emu_t* emu, glprocaddress_t procaddr, const char* rname);
|
||||
EXPORT void* my32_glXGetProcAddress(x64emu_t* emu, void* name)
|
||||
{
|
||||
khint_t k;
|
||||
const char* rname = (const char*)name;
|
||||
return getGLProcAddress32(emu, my_lib->w.priv, rname);
|
||||
}
|
||||
EXPORT void* my32_glXGetProcAddressARB(x64emu_t* emu, void* name) __attribute__((alias("my32_glXGetProcAddress")));
|
||||
|
||||
typedef int (*iFi_t)(int);
|
||||
typedef void (*vFpp_t)(void*, void*);
|
||||
typedef void (*vFppp_t)(void*, void*, void*);
|
||||
typedef void (*vFppi_t)(void*, void*, int);
|
||||
typedef void*(*pFp_t)(void*);
|
||||
typedef void (*debugProc_t)(int32_t, int32_t, uint32_t, int32_t, int32_t, void*, void*);
|
||||
|
||||
typedef struct gl_wrappers_s {
|
||||
glprocaddress_t procaddress;
|
||||
kh_symbolmap_t *glwrappers; // the map of wrapper for glProcs (for GLX or SDL1/2)
|
||||
kh_symbolmap_t *glmymap; // link to the mysymbolmap of libGL
|
||||
} gl_wrappers_t;
|
||||
|
||||
KHASH_MAP_INIT_INT64(gl_wrappers, gl_wrappers_t*)
|
||||
|
||||
static kh_gl_wrappers_t *gl_wrappers = NULL;
|
||||
|
||||
#define SUPER() \
|
||||
GO(0) \
|
||||
GO(1) \
|
||||
GO(2) \
|
||||
GO(3) \
|
||||
GO(4)
|
||||
|
||||
// debug_callback ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my_debug_callback_fct_##A = 0; \
|
||||
static void my_debug_callback_##A(int32_t a, int32_t b, uint32_t c, int32_t d, int32_t e, const char* f, const void* g) \
|
||||
{ \
|
||||
RunFunctionFmt(my_debug_callback_fct_##A, "iiuiipp", a, b, c, d, e, f, g); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_debug_callback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my_debug_callback_fct_##A == (uintptr_t)fct) return my_debug_callback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_debug_callback_fct_##A == 0) {my_debug_callback_fct_##A = (uintptr_t)fct; return my_debug_callback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL debug_callback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// egl_debug_callback ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my_egl_debug_callback_fct_##A = 0; \
|
||||
static void my_egl_debug_callback_##A(int a, void* b, int c, void* d, void* e, const char* f) \
|
||||
{ \
|
||||
RunFunctionFmt(my_egl_debug_callback_fct_##A, "ipippp", a, b, c, d, e, f); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_egl_debug_callback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my_egl_debug_callback_fct_##A == (uintptr_t)fct) return my_egl_debug_callback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_egl_debug_callback_fct_##A == 0) {my_egl_debug_callback_fct_##A = (uintptr_t)fct; return my_egl_debug_callback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL egl_debug_callback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// program_callback ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my_program_callback_fct_##A = 0; \
|
||||
static void my_program_callback_##A(int32_t a, void* b) \
|
||||
{ \
|
||||
RunFunctionFmt(my_program_callback_fct_##A, "ip", a, b); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_program_callback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my_program_callback_fct_##A == (uintptr_t)fct) return my_program_callback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_program_callback_fct_##A == 0) {my_program_callback_fct_##A = (uintptr_t)fct; return my_program_callback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL program_callback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// set_blob_func ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my_set_blob_func_fct_##A = 0; \
|
||||
static void my_set_blob_func_##A(void* a, ssize_t b, void* c, ssize_t d) \
|
||||
{ \
|
||||
RunFunctionFmt(my_set_blob_func_fct_##A, "plpl", a, b, c, d); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_set_blob_func_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my_set_blob_func_fct_##A == (uintptr_t)fct) return my_set_blob_func_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_set_blob_func_fct_##A == 0) {my_set_blob_func_fct_##A = (uintptr_t)fct; return my_set_blob_func_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL set_blob_func callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// get_blob_func ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my_get_blob_func_fct_##A = 0; \
|
||||
static ssize_t my_get_blob_func_##A(void* a, ssize_t b, void* c, ssize_t d) \
|
||||
{ \
|
||||
return (ssize_t)RunFunctionFmt(my_get_blob_func_fct_##A, "plpl", a, b, c, d); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_get_blob_func_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my_get_blob_func_fct_##A == (uintptr_t)fct) return my_get_blob_func_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_get_blob_func_fct_##A == 0) {my_get_blob_func_fct_##A = (uintptr_t)fct; return my_get_blob_func_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL get_blob_func callback\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// glDebugMessageCallback ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my32_glDebugMessageCallback_fct_##A = NULL; \
|
||||
static void my32_glDebugMessageCallback_##A(x64emu_t* emu, void* prod, void* param) \
|
||||
{ \
|
||||
if(!my32_glDebugMessageCallback_fct_##A) \
|
||||
return; \
|
||||
my32_glDebugMessageCallback_fct_##A(find_debug_callback_Fct(prod), param); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glDebugMessageCallback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glDebugMessageCallback_fct_##A == (vFpp_t)fct) return my32_glDebugMessageCallback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glDebugMessageCallback_fct_##A == 0) {my32_glDebugMessageCallback_fct_##A = (vFpp_t)fct; return my32_glDebugMessageCallback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glDebugMessageCallback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// glDebugMessageCallbackARB ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my32_glDebugMessageCallbackARB_fct_##A = NULL; \
|
||||
static void my32_glDebugMessageCallbackARB_##A(x64emu_t* emu, void* prod, void* param) \
|
||||
{ \
|
||||
if(!my32_glDebugMessageCallbackARB_fct_##A) \
|
||||
return; \
|
||||
my32_glDebugMessageCallbackARB_fct_##A(find_debug_callback_Fct(prod), param); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glDebugMessageCallbackARB_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glDebugMessageCallbackARB_fct_##A == (vFpp_t)fct) return my32_glDebugMessageCallbackARB_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glDebugMessageCallbackARB_fct_##A == 0) {my32_glDebugMessageCallbackARB_fct_##A = (vFpp_t)fct; return my32_glDebugMessageCallbackARB_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glDebugMessageCallbackARB callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// glDebugMessageCallbackAMD ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my32_glDebugMessageCallbackAMD_fct_##A = NULL; \
|
||||
static void my32_glDebugMessageCallbackAMD_##A(x64emu_t* emu, void* prod, void* param) \
|
||||
{ \
|
||||
if(!my32_glDebugMessageCallbackAMD_fct_##A) \
|
||||
return; \
|
||||
my32_glDebugMessageCallbackAMD_fct_##A(find_debug_callback_Fct(prod), param); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glDebugMessageCallbackAMD_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glDebugMessageCallbackAMD_fct_##A == (vFpp_t)fct) return my32_glDebugMessageCallbackAMD_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glDebugMessageCallbackAMD_fct_##A == 0) {my32_glDebugMessageCallbackAMD_fct_##A = (vFpp_t)fct; return my32_glDebugMessageCallbackAMD_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glDebugMessageCallbackAMD callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// glDebugMessageCallbackKHR ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my32_glDebugMessageCallbackKHR_fct_##A = NULL; \
|
||||
static void my32_glDebugMessageCallbackKHR_##A(x64emu_t* emu, void* prod, void* param) \
|
||||
{ \
|
||||
if(!my32_glDebugMessageCallbackKHR_fct_##A) \
|
||||
return; \
|
||||
my32_glDebugMessageCallbackKHR_fct_##A(find_debug_callback_Fct(prod), param); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glDebugMessageCallbackKHR_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glDebugMessageCallbackKHR_fct_##A == (vFpp_t)fct) return my32_glDebugMessageCallbackKHR_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glDebugMessageCallbackKHR_fct_##A == 0) {my32_glDebugMessageCallbackKHR_fct_##A = (vFpp_t)fct; return my32_glDebugMessageCallbackKHR_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glDebugMessageCallbackKHR callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// eglDebugMessageControlKHR ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my_eglDebugMessageControlKHR_fct_##A = NULL; \
|
||||
static void my_eglDebugMessageControlKHR_##A(x64emu_t* emu, void* prod, void* param) \
|
||||
{ \
|
||||
if(!my_eglDebugMessageControlKHR_fct_##A) \
|
||||
return; \
|
||||
my_eglDebugMessageControlKHR_fct_##A(find_egl_debug_callback_Fct(prod), param); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_eglDebugMessageControlKHR_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my_eglDebugMessageControlKHR_fct_##A == (vFpp_t)fct) return my_eglDebugMessageControlKHR_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_eglDebugMessageControlKHR_fct_##A == 0) {my_eglDebugMessageControlKHR_fct_##A = (vFpp_t)fct; return my_eglDebugMessageControlKHR_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL eglDebugMessageControlKHR callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// eglSetBlobCacheFuncsANDROID ...
|
||||
#define GO(A) \
|
||||
static vFppp_t my_eglSetBlobCacheFuncsANDROID_fct_##A = NULL; \
|
||||
static void my_eglSetBlobCacheFuncsANDROID_##A(x64emu_t* emu, void* dpy, void* set, void* get) \
|
||||
{ \
|
||||
if(!my_eglSetBlobCacheFuncsANDROID_fct_##A) \
|
||||
return; \
|
||||
my_eglSetBlobCacheFuncsANDROID_fct_##A(dpy, find_set_blob_func_Fct(set), find_get_blob_func_Fct(get)); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_eglSetBlobCacheFuncsANDROID_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my_eglSetBlobCacheFuncsANDROID_fct_##A == (vFppp_t)fct) return my_eglSetBlobCacheFuncsANDROID_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my_eglSetBlobCacheFuncsANDROID_fct_##A == 0) {my_eglSetBlobCacheFuncsANDROID_fct_##A = (vFppp_t)fct; return my_eglSetBlobCacheFuncsANDROID_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL eglSetBlobCacheFuncsANDROID callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// glXSwapIntervalMESA ...
|
||||
#define GO(A) \
|
||||
static iFi_t my32_glXSwapIntervalMESA_fct_##A = NULL; \
|
||||
static int my32_glXSwapIntervalMESA_##A(int interval) \
|
||||
{ \
|
||||
if(!my32_glXSwapIntervalMESA_fct_##A) \
|
||||
return 0; \
|
||||
return my32_glXSwapIntervalMESA_fct_##A(interval); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
|
||||
static int my_dummy32_glXSwapIntervalMESA(int interval)
|
||||
{
|
||||
return 5; // GLX_BAD_CONTEXT
|
||||
}
|
||||
|
||||
static void* find_glXSwapIntervalMESA_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return my_dummy32_glXSwapIntervalMESA;
|
||||
#define GO(A) if(my32_glXSwapIntervalMESA_fct_##A == (iFi_t)fct) return my32_glXSwapIntervalMESA_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glXSwapIntervalMESA_fct_##A == 0) {my32_glXSwapIntervalMESA_fct_##A = (iFi_t)fct; return my32_glXSwapIntervalMESA_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glXSwapIntervalMESA callback\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// glXSwapIntervalEXT ...
|
||||
#define GO(A) \
|
||||
static vFppi_t my32_glXSwapIntervalEXT_fct_##A = NULL; \
|
||||
static void my32_glXSwapIntervalEXT_##A(void* dpy, void* drawable, int interval) \
|
||||
{ \
|
||||
if (!my32_glXSwapIntervalEXT_fct_##A) \
|
||||
return; \
|
||||
my32_glXSwapIntervalEXT_fct_##A(dpy, drawable, interval); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
|
||||
static void my_dummy32_glXSwapIntervalEXT(void* dpy, void* drawable, int interval) {}
|
||||
|
||||
static void* find_glXSwapIntervalEXT_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return my_dummy32_glXSwapIntervalEXT;
|
||||
#define GO(A) if(my32_glXSwapIntervalEXT_fct_##A == (vFppi_t)fct) return my32_glXSwapIntervalEXT_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glXSwapIntervalEXT_fct_##A == 0) {my32_glXSwapIntervalEXT_fct_##A = (vFppi_t)fct; return my32_glXSwapIntervalEXT_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glXSwapIntervalEXT callback\n");
|
||||
return NULL;
|
||||
}
|
||||
|
||||
// glProgramCallbackMESA ...
|
||||
#define GO(A) \
|
||||
static vFpp_t my32_glProgramCallbackMESA_fct_##A = NULL; \
|
||||
static void my32_glProgramCallbackMESA_##A(x64emu_t* emu, void* f, void* data)\
|
||||
{ \
|
||||
if(!my32_glProgramCallbackMESA_fct_##A) \
|
||||
return; \
|
||||
my32_glProgramCallbackMESA_fct_##A(find_program_callback_Fct(f), data); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glProgramCallbackMESA_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glProgramCallbackMESA_fct_##A == (vFpp_t)fct) return my32_glProgramCallbackMESA_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glProgramCallbackMESA_fct_##A == 0) {my32_glProgramCallbackMESA_fct_##A = (vFpp_t)fct; return my32_glProgramCallbackMESA_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glProgramCallbackMESA callback\n");
|
||||
return NULL;
|
||||
}
|
||||
void* my_GetVkProcAddr(x64emu_t* emu, void* name, void*(*getaddr)(void*)); // defined in wrappedvulkan.c
|
||||
// glGetVkProcAddrNV ...
|
||||
#define GO(A) \
|
||||
static pFp_t my32_glGetVkProcAddrNV_fct_##A = NULL; \
|
||||
static void* my32_glGetVkProcAddrNV_##A(x64emu_t* emu, void* name) \
|
||||
{ \
|
||||
if(!my32_glGetVkProcAddrNV_fct_##A) \
|
||||
return NULL; \
|
||||
return my_GetVkProcAddr(emu, name, my32_glGetVkProcAddrNV_fct_##A); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_glGetVkProcAddrNV_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
#define GO(A) if(my32_glGetVkProcAddrNV_fct_##A == (pFp_t)fct) return my32_glGetVkProcAddrNV_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_glGetVkProcAddrNV_fct_##A == 0) {my32_glGetVkProcAddrNV_fct_##A = (pFp_t)fct; return my32_glGetVkProcAddrNV_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for libGL glGetVkProcAddrNV callback\n");
|
||||
return NULL;
|
||||
}
|
||||
#undef SUPER
|
||||
|
||||
#define PRE_INIT if(box64_libGL) {lib->w.lib = dlopen(box64_libGL, RTLD_LAZY | RTLD_GLOBAL); lib->path = strdup(box64_libGL);} else
|
||||
#define CUSTOM_INIT \
|
||||
my_lib = lib; \
|
||||
lib->w.priv = dlsym(lib->w.lib, "glXGetProcAddress"); \
|
||||
void* symb = dlsym(lib->w.lib, "glDebugMessageCallback"); \
|
||||
if(symb) { \
|
||||
k = kh_get(symbolmap, lib->w.mysymbolmap, "glDebugMessageCallback"); \
|
||||
symbol1_t *s = &kh_value(lib->w.mysymbolmap, k); \
|
||||
s->resolved = 1; \
|
||||
s->addr = AddBridge(lib->w.bridge, s->w, find_glDebugMessageCallback_Fct(symb), 0, "glDebugMessageCallback"); \
|
||||
} \
|
||||
symb = dlsym(lib->w.lib, "glXSwapIntervalMESA"); \
|
||||
if(symb) { \
|
||||
k = kh_get(symbolmap, lib->w.mysymbolmap, "glXSwapIntervalMESA"); \
|
||||
symbol1_t *s = &kh_value(lib->w.mysymbolmap, k); \
|
||||
s->resolved = 1; \
|
||||
s->addr = AddBridge(lib->w.bridge, s->w, find_glXSwapIntervalMESA_Fct(symb), 0, "glXSwapIntervalMESA"); \
|
||||
} \
|
||||
symb = dlsym(lib->w.lib, "glXSwapIntervalEXT"); \
|
||||
if(symb) { \
|
||||
k = kh_get(symbolmap, lib->w.mysymbolmap, "glXSwapIntervalEXT"); \
|
||||
symbol1_t *s = &kh_value(lib->w.mysymbolmap, k); \
|
||||
s->resolved = 1; \
|
||||
s->addr = AddBridge(lib->w.bridge, s->w, find_glXSwapIntervalEXT_Fct(symb), 0, "glXSwapIntervalEXT"); \
|
||||
} \
|
||||
|
||||
#include "wrappedlib_init32.h"
|
||||
|
||||
#define SUPER() \
|
||||
GO(vFpp_t, glDebugMessageCallback) \
|
||||
GO(vFpp_t, glDebugMessageCallbackARB) \
|
||||
GO(vFpp_t, glDebugMessageCallbackAMD) \
|
||||
GO(vFpp_t, glDebugMessageCallbackKHR) \
|
||||
GO(vFpp_t, eglDebugMessageControlKHR) \
|
||||
GO(iFi_t, glXSwapIntervalMESA) \
|
||||
GO(vFppi_t, glXSwapIntervalEXT) \
|
||||
GO(vFpp_t, glProgramCallbackMESA) \
|
||||
GO(pFp_t, glGetVkProcAddrNV) \
|
||||
GO(vFppp_t, eglSetBlobCacheFuncsANDROID) \
|
||||
|
||||
|
||||
gl_wrappers_t* getGLProcWrapper32(box64context_t* context, glprocaddress_t procaddress)
|
||||
{
|
||||
int cnt, ret;
|
||||
khint_t k;
|
||||
if(!gl_wrappers) {
|
||||
gl_wrappers = kh_init(gl_wrappers);
|
||||
}
|
||||
k = kh_put(gl_wrappers, gl_wrappers, (uintptr_t)procaddress, &ret);
|
||||
if(!ret)
|
||||
return kh_value(gl_wrappers, k);
|
||||
gl_wrappers_t* wrappers = kh_value(gl_wrappers, k) = (gl_wrappers_t*)calloc(1, sizeof(gl_wrappers_t));
|
||||
|
||||
wrappers->procaddress = procaddress;
|
||||
wrappers->glwrappers = kh_init(symbolmap);
|
||||
// populates maps...
|
||||
cnt = sizeof(libglsymbolmap)/sizeof(map_onesymbol_t);
|
||||
for (int i=0; i<cnt; ++i) {
|
||||
k = kh_put(symbolmap, wrappers->glwrappers, libglsymbolmap[i].name, &ret);
|
||||
kh_value(wrappers->glwrappers, k).w = libglsymbolmap[i].w;
|
||||
kh_value(wrappers->glwrappers, k).resolved = 0;
|
||||
}
|
||||
// and the my_ symbols map
|
||||
cnt = sizeof(MAPNAME(mysymbolmap))/sizeof(map_onesymbol_t);
|
||||
for (int i=0; i<cnt; ++i) {
|
||||
k = kh_put(symbolmap, wrappers->glwrappers, libglmysymbolmap[i].name, &ret);
|
||||
kh_value(wrappers->glwrappers, k).w = libglmysymbolmap[i].w;
|
||||
kh_value(wrappers->glwrappers, k).resolved = 0;
|
||||
}
|
||||
// my_* map
|
||||
wrappers->glmymap = kh_init(symbolmap);
|
||||
cnt = sizeof(MAPNAME(mysymbolmap))/sizeof(map_onesymbol_t);
|
||||
for (int i=0; i<cnt; ++i) {
|
||||
k = kh_put(symbolmap, wrappers->glmymap, libglmysymbolmap[i].name, &ret);
|
||||
kh_value(wrappers->glmymap, k).w = libglmysymbolmap[i].w;
|
||||
kh_value(wrappers->glmymap, k).resolved = 0;
|
||||
}
|
||||
return wrappers;
|
||||
}
|
||||
|
||||
void* getGLProcAddress32(x64emu_t* emu, glprocaddress_t procaddr, const char* rname)
|
||||
{
|
||||
khint_t k;
|
||||
printf_dlsym(LOG_DEBUG, "Calling getGLProcAddress32[%p](\"%s\") => ", procaddr, rname);
|
||||
gl_wrappers_t* wrappers = getGLProcWrapper32(emu->context, procaddr);
|
||||
// check if glxprocaddress is filled, and search for lib and fill it if needed
|
||||
// get proc adress using actual glXGetProcAddress
|
||||
k = kh_get(symbolmap, wrappers->glmymap, rname);
|
||||
int is_my = (k==kh_end(wrappers->glmymap))?0:1;
|
||||
void* symbol;
|
||||
if(is_my) {
|
||||
// try again, by using custom "my_" now...
|
||||
#define GO(A, B) else if(!strcmp(rname, #B)) symbol = find_##B##_Fct(procaddr(rname));
|
||||
if(0) {}
|
||||
SUPER()
|
||||
else {
|
||||
if(strcmp(rname, "glXGetProcAddress") && strcmp(rname, "glXGetProcAddressARB")) {
|
||||
printf_log(LOG_NONE, "Warning, %s defined as GOM, but find_%s_Fct not defined\n", rname, rname);
|
||||
}
|
||||
char tmp[200];
|
||||
strcpy(tmp, "my_");
|
||||
strcat(tmp, rname);
|
||||
symbol = dlsym(emu->context->box64lib, tmp);
|
||||
}
|
||||
#undef GO
|
||||
#undef SUPER
|
||||
} else
|
||||
symbol = procaddr(rname);
|
||||
if(!symbol) {
|
||||
printf_dlsym(LOG_DEBUG, "%p\n", NULL);
|
||||
return NULL; // easy
|
||||
}
|
||||
// check if alread bridged
|
||||
uintptr_t ret = CheckBridged(emu->context->system, symbol);
|
||||
if(ret) {
|
||||
printf_dlsym(LOG_DEBUG, "%p\n", (void*)ret);
|
||||
return (void*)ret; // already bridged
|
||||
}
|
||||
// get wrapper
|
||||
k = kh_get(symbolmap, wrappers->glwrappers, rname);
|
||||
if(k==kh_end(wrappers->glwrappers) && strstr(rname, "ARB")==NULL) {
|
||||
// try again, adding ARB at the end if not present
|
||||
char tmp[200];
|
||||
strcpy(tmp, rname);
|
||||
strcat(tmp, "ARB");
|
||||
k = kh_get(symbolmap, wrappers->glwrappers, tmp);
|
||||
}
|
||||
if(k==kh_end(wrappers->glwrappers) && strstr(rname, "EXT")==NULL) {
|
||||
// try again, adding EXT at the end if not present
|
||||
char tmp[200];
|
||||
strcpy(tmp, rname);
|
||||
strcat(tmp, "EXT");
|
||||
k = kh_get(symbolmap, wrappers->glwrappers, tmp);
|
||||
}
|
||||
if(k==kh_end(wrappers->glwrappers)) {
|
||||
printf_dlsym(LOG_DEBUG, "%p\n", NULL);
|
||||
printf_dlsym(LOG_INFO, "Warning, no wrapper for %s\n", rname);
|
||||
return NULL;
|
||||
}
|
||||
symbol1_t* s = &kh_value(wrappers->glwrappers, k);
|
||||
if(!s->resolved) {
|
||||
const char* constname = kh_key(wrappers->glwrappers, k);
|
||||
AddOffsetSymbol(emu->context->maplib, symbol, rname);
|
||||
s->addr = AddCheckBridge(emu->context->system, s->w, symbol, 0, constname);
|
||||
s->resolved = 1;
|
||||
}
|
||||
ret = s->addr;
|
||||
printf_dlsym(LOG_DEBUG, "%p\n", (void*)ret);
|
||||
return (void*)ret;
|
||||
}
|
4063
src/wrapped32/wrappedlibgl_private.h
Normal file
4063
src/wrapped32/wrappedlibgl_private.h
Normal file
File diff suppressed because it is too large
Load Diff
@ -131,11 +131,11 @@ GO(pthread_rwlockattr_init, iFp)
|
||||
GO(pthread_rwlockattr_setkind_np, iFpi)
|
||||
// pthread_rwlockattr_setpshared
|
||||
// __pthread_rwlock_destroy
|
||||
GO(pthread_rwlock_destroy, iFp)
|
||||
GOM(pthread_rwlock_destroy, iFp) //%noE
|
||||
GOM(__pthread_rwlock_init, iFpp) //%noE
|
||||
GOM(pthread_rwlock_init, iFpp) //%noE
|
||||
GO(__pthread_rwlock_rdlock, iFp)
|
||||
GOM(pthread_rwlock_rdlock, iFp) //%noE
|
||||
GO(pthread_rwlock_rdlock, iFp)
|
||||
// pthread_rwlock_timedrdlock
|
||||
// pthread_rwlock_timedwrlock
|
||||
// __pthread_rwlock_tryrdlock
|
||||
|
538
src/wrapped32/wrappedsdl1.c
Normal file
538
src/wrapped32/wrappedsdl1.c
Normal file
@ -0,0 +1,538 @@
|
||||
#include <stdio.h>
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#define _GNU_SOURCE /* See feature_test_macros(7) */
|
||||
#include <dlfcn.h>
|
||||
|
||||
#include "wrappedlibs.h"
|
||||
|
||||
#include "wrapper32.h"
|
||||
#include "debug.h"
|
||||
#include "bridge.h"
|
||||
#include "librarian/library_private.h"
|
||||
#include "x64emu.h"
|
||||
#include "callback.h"
|
||||
#include "librarian.h"
|
||||
#include "emu/x64emu_private.h"
|
||||
#include "box32context.h"
|
||||
#include "sdl1rwops.h"
|
||||
#include "gltools.h"
|
||||
|
||||
#include "x64trace.h"
|
||||
#include "threads.h"
|
||||
|
||||
#include "sdl1align32.h"
|
||||
|
||||
extern const char* sdl1Name;
|
||||
#define LIBNAME sdl1
|
||||
|
||||
static int sdl_Yes() {return 1;}
|
||||
static int sdl_No() {return 0;}
|
||||
EXPORT int my32_SDL_Has3DNow() __attribute__((alias("sdl_No")));
|
||||
EXPORT int my32_SDL_Has3DNowExt() __attribute__((alias("sdl_No")));
|
||||
EXPORT int my32_SDL_HasAltiVec() __attribute__((alias("sdl_No")));
|
||||
EXPORT int my32_SDL_HasMMX() __attribute__((alias("sdl_Yes")));
|
||||
EXPORT int my32_SDL_HasMMXExt() __attribute__((alias("sdl_Yes")));
|
||||
EXPORT int my32_SDL_HasRDTSC() __attribute__((alias("sdl_Yes")));
|
||||
EXPORT int my32_SDL_HasSSE() __attribute__((alias("sdl_Yes")));
|
||||
EXPORT int my32_SDL_HasSSE2() __attribute__((alias("sdl_Yes")));
|
||||
|
||||
typedef struct {
|
||||
int32_t freq;
|
||||
uint16_t format;
|
||||
uint8_t channels;
|
||||
uint8_t silence;
|
||||
uint16_t samples;
|
||||
uint32_t size;
|
||||
void (*callback)(void *userdata, uint8_t *stream, int32_t len);
|
||||
void *userdata;
|
||||
} SDL_AudioSpec;
|
||||
|
||||
typedef struct {
|
||||
int32_t freq;
|
||||
uint16_t format;
|
||||
uint8_t channels;
|
||||
uint8_t silence;
|
||||
uint16_t samples;
|
||||
uint32_t size;
|
||||
ptr_t callback; //void (*callback)(void *userdata, uint8_t *stream, int32_t len);
|
||||
ptr_t userdata; //void *userdata;
|
||||
} SDL_AudioSpec32;
|
||||
|
||||
EXPORT void my32_SDL_Quit();
|
||||
|
||||
#define ADDED_FUNCTIONS() \
|
||||
GO(SDL_AllocRW, sdl1_allocrw) \
|
||||
GO(SDL_FreeRW, sdl1_freerw)
|
||||
|
||||
#define ADDED_FINI() \
|
||||
my32_SDL_Quit();
|
||||
|
||||
#include "generated/wrappedsdl1types32.h"
|
||||
|
||||
#include "wrappercallback32.h"
|
||||
|
||||
// event filter. Needs to be global, but there is only one, so that's should be fine
|
||||
static x64emu_t *sdl1_evtfilter = NULL;
|
||||
static void* sdl1_evtfnc = NULL;
|
||||
static int sdl1_evtautofree = 0;
|
||||
static int sdl1_evtinside = 0;
|
||||
|
||||
#define SUPER() \
|
||||
GO(0) \
|
||||
GO(1) \
|
||||
GO(2) \
|
||||
GO(3) \
|
||||
GO(4)
|
||||
|
||||
// AudioCallback ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my32_AudioCallback_fct_##A = 0; \
|
||||
static void my32_AudioCallback_##A(void *userdata, uint8_t *stream, int32_t len) \
|
||||
{ \
|
||||
RunFunctionFmt(my32_AudioCallback_fct_##A, "ppi", userdata, stream, len); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_AudioCallback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my32_AudioCallback_fct_##A == (uintptr_t)fct) return my32_AudioCallback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_AudioCallback_fct_##A == 0) {my32_AudioCallback_fct_##A = (uintptr_t)fct; return my32_AudioCallback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for SDL1 AudioCallback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// TimerCallback ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my32_TimerCallback_fct_##A = 0; \
|
||||
static uint32_t my32_TimerCallback_##A(uint32_t interval, void *userdata) \
|
||||
{ \
|
||||
return (uint32_t)RunFunctionFmt(my32_TimerCallback_fct_##A, "up", interval, userdata); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_TimerCallback_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my32_TimerCallback_fct_##A == (uintptr_t)fct) return my32_TimerCallback_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_TimerCallback_fct_##A == 0) {my32_TimerCallback_fct_##A = (uintptr_t)fct; return my32_TimerCallback_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for SDL1 TimerCallback callback\n");
|
||||
return NULL;
|
||||
}
|
||||
// EvtFilter ...
|
||||
#define GO(A) \
|
||||
static uintptr_t my32_EvtFilter_fct_##A = 0; \
|
||||
static int my32_EvtFilter_##A(void* p) \
|
||||
{ \
|
||||
return RunFunctionFmt(my32_EvtFilter_fct_##A, "p", p); \
|
||||
}
|
||||
SUPER()
|
||||
#undef GO
|
||||
static void* find_EvtFilter_Fct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(GetNativeFnc((uintptr_t)fct)) return GetNativeFnc((uintptr_t)fct);
|
||||
#define GO(A) if(my32_EvtFilter_fct_##A == (uintptr_t)fct) return my32_EvtFilter_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#define GO(A) if(my32_EvtFilter_fct_##A == 0) {my32_EvtFilter_fct_##A = (uintptr_t)fct; return my32_EvtFilter_##A; }
|
||||
SUPER()
|
||||
#undef GO
|
||||
printf_log(LOG_NONE, "Warning, no more slot for SDL1 EvtFilter callback\n");
|
||||
return NULL;
|
||||
}
|
||||
static void* reverse_EvtFilterFct(void* fct)
|
||||
{
|
||||
if(!fct) return fct;
|
||||
if(CheckBridged(my_lib->w.bridge, fct))
|
||||
return (void*)CheckBridged(my_lib->w.bridge, fct);
|
||||
#define GO(A) if(my32_EvtFilter_##A == fct) return (void*)my32_EvtFilter_fct_##A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
return (void*)AddBridge(my_lib->w.bridge, iFp_32, fct, 0, NULL);
|
||||
}
|
||||
#undef SUPER
|
||||
|
||||
// TODO: track the memory for those callback
|
||||
EXPORT int my32_SDL_OpenAudio(x64emu_t* emu, void* d, void* o)
|
||||
{
|
||||
SDL_AudioSpec desired = {0};
|
||||
SDL_AudioSpec output = {0};
|
||||
SDL_AudioSpec32 *d_ = d;
|
||||
desired.channels = d_->channels;
|
||||
desired.format = d_->format;
|
||||
desired.freq = d_->freq;
|
||||
desired.samples = d_->samples;
|
||||
desired.silence = d_->silence;
|
||||
desired.size = d_->size;
|
||||
desired.userdata = from_ptrv(d_->userdata);
|
||||
desired.callback = find_AudioCallback_Fct(from_ptrv(d_->callback));
|
||||
int ret = my->SDL_OpenAudio(&desired, &output);
|
||||
if (ret!=0) {
|
||||
return ret;
|
||||
}
|
||||
// put back stuff in place?
|
||||
SDL_AudioSpec32* o_ = o;
|
||||
o_->channels = output.channels;
|
||||
o_->format = output.format;
|
||||
o_->freq = output.freq;
|
||||
o_->samples = output.samples;
|
||||
o_->silence = output.silence;
|
||||
o_->size = output.size;
|
||||
o_->userdata = o_->callback = 0;
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
//EXPORT void *my32_SDL_LoadBMP_RW(x64emu_t* emu, void* a, int b)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// void* r = my->SDL_LoadBMP_RW(rw, b);
|
||||
// if(b==0)
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT int32_t my32_SDL_SaveBMP_RW(x64emu_t* emu, void* a, void* b, int c)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// int32_t r = my->SDL_SaveBMP_RW(rw, b, c);
|
||||
// if(c==0)
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT void *my32_SDL_LoadWAV_RW(x64emu_t* emu, void* a, int b, void* c, void* d, void* e)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// void* r = my->SDL_LoadWAV_RW(rw, b, c, d, e);
|
||||
// if(b==0)
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_ReadBE16(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_ReadBE16(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_ReadBE32(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_ReadBE32(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint64_t my32_SDL_ReadBE64(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint64_t r = my->SDL_ReadBE64(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_ReadLE16(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_ReadLE16(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_ReadLE32(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_ReadLE32(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint64_t my32_SDL_ReadLE64(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint64_t r = my->SDL_ReadLE64(rw);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteBE16(x64emu_t* emu, void* a, uint16_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteBE16(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteBE32(x64emu_t* emu, void* a, uint32_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteBE32(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteBE64(x64emu_t* emu, void* a, uint64_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteBE64(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteLE16(x64emu_t* emu, void* a, uint16_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteLE16(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteLE32(x64emu_t* emu, void* a, uint32_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteLE32(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
//EXPORT uint32_t my32_SDL_WriteLE64(x64emu_t* emu, void* a, uint64_t v)
|
||||
//{
|
||||
// SDL1_RWops_t* rw = RWNativeStart(emu, (SDL1_RWops_t*)a);
|
||||
// uint32_t r = my->SDL_WriteLE64(rw, v);
|
||||
// RWNativeEnd(rw);
|
||||
// return r;
|
||||
//}
|
||||
|
||||
// SDL1 doesn't really used rw_ops->type, but box64 does, so set sensible value (from SDL2)....
|
||||
//EXPORT void *my32_SDL_RWFromConstMem(x64emu_t* emu, void* a, int b)
|
||||
//{
|
||||
// SDL1_RWops_t* r = (SDL1_RWops_t*)my->SDL_RWFromConstMem(a, b);
|
||||
// RWSetType(r, 5);
|
||||
// return AddNativeRW(emu, r);
|
||||
//}
|
||||
//EXPORT void *my32_SDL_RWFromFP(x64emu_t* emu, void* a, int b)
|
||||
//{
|
||||
// SDL1_RWops_t* r = (SDL1_RWops_t*)my->SDL_RWFromFP(a, b);
|
||||
// RWSetType(r, 2);
|
||||
// return AddNativeRW(emu, r);
|
||||
//}
|
||||
//EXPORT void *my32_SDL_RWFromFile(x64emu_t* emu, void* a, void* b)
|
||||
//{
|
||||
// SDL1_RWops_t* r = (SDL1_RWops_t*)my->SDL_RWFromFile(a, b);
|
||||
// RWSetType(r, 2);
|
||||
// return AddNativeRW(emu, r);
|
||||
//}
|
||||
//EXPORT void *my32_SDL_RWFromMem(x64emu_t* emu, void* a, int b)
|
||||
//{
|
||||
// SDL1_RWops_t* r = (SDL1_RWops_t*)my->SDL_RWFromMem(a, b);
|
||||
// RWSetType(r, 4);
|
||||
// return AddNativeRW(emu, r);
|
||||
//}
|
||||
//
|
||||
//EXPORT void *my32_SDL_AddTimer(x64emu_t* emu, uint32_t a, void* cb, void* p)
|
||||
//{
|
||||
// return my->SDL_AddTimer(a, find_TimerCallback_Fct(cb), p);
|
||||
//}
|
||||
//
|
||||
//EXPORT int my32_SDL_RemoveTimer(x64emu_t* emu, void *t)
|
||||
//{
|
||||
// return my->SDL_RemoveTimer(t);
|
||||
//}
|
||||
|
||||
//EXPORT int32_t my32_SDL_SetTimer(x64emu_t* emu, uint32_t t, void* p)
|
||||
//{
|
||||
// return my->SDL_SetTimer(t, find_TimerCallback_Fct(p));
|
||||
//}
|
||||
#if 0
|
||||
EXPORT int32_t my32_SDL_BuildAudioCVT(x64emu_t* emu, void* a, uint32_t b, uint32_t c, int32_t d, uint32_t e, uint32_t f, int32_t g)
|
||||
{
|
||||
printf_log(LOG_NONE, "Error, using Unimplemented SDL1 SDL_BuildAudioCVT\n");
|
||||
emu->quit = 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
EXPORT int32_t my32_SDL_ConvertAudio(x64emu_t* emu, void* a)
|
||||
{
|
||||
printf_log(LOG_NONE, "Error, using Unimplemented SDL1 SDL_ConvertAudio\n");
|
||||
emu->quit = 1;
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
//EXPORT void my32_SDL_SetEventFilter(x64emu_t* emu, void* a)
|
||||
//{
|
||||
// my->SDL_SetEventFilter(find_EvtFilter_Fct(a));
|
||||
//}
|
||||
//EXPORT void *my32_SDL_GetEventFilter(x64emu_t* emu)
|
||||
//{
|
||||
// return reverse_EvtFilterFct(my->SDL_GetEventFilter());
|
||||
//}
|
||||
void* my32_prepare_thread(x64emu_t *emu, void* f, void* arg, int ssize, void** pet);
|
||||
EXPORT void *my32_SDL_CreateThread(x64emu_t* emu, void* cb, void* p)
|
||||
{
|
||||
void* et = NULL;
|
||||
void* fnc = my32_prepare_thread(emu, cb, p, 0, &et);
|
||||
return my->SDL_CreateThread(fnc, et);
|
||||
}
|
||||
|
||||
EXPORT void my32_SDL_KillThread(x64emu_t* emu, void* p)
|
||||
{
|
||||
my->SDL_KillThread(p);
|
||||
}
|
||||
|
||||
EXPORT void* my32_SDL_GL_GetProcAddress(x64emu_t* emu, void* name)
|
||||
{
|
||||
khint_t k;
|
||||
const char* rname = (const char*)name;
|
||||
return getGLProcAddress(emu, (glprocaddress_t)my->SDL_GL_GetProcAddress, rname);
|
||||
}
|
||||
|
||||
// DL functions from wrappedlibdl.c
|
||||
void* my_dlopen(x64emu_t* emu, void *filename, int flag);
|
||||
int my_dlclose(x64emu_t* emu, void *handle);
|
||||
void* my_dlsym(x64emu_t* emu, void *handle, void *symbol);
|
||||
EXPORT void* my32_SDL_LoadObject(x64emu_t* emu, void* sofile)
|
||||
{
|
||||
return my_dlopen(emu, sofile, 0); // TODO: check correct flag value...
|
||||
}
|
||||
EXPORT void my32_SDL_UnloadObject(x64emu_t* emu, void* handle)
|
||||
{
|
||||
my_dlclose(emu, handle);
|
||||
}
|
||||
EXPORT void* my32_SDL_LoadFunction(x64emu_t* emu, void* handle, void* name)
|
||||
{
|
||||
return my_dlsym(emu, handle, name);
|
||||
}
|
||||
|
||||
static my_SDL_Surface_t* sdl1_videomode_org = NULL;
|
||||
static my_SDL_Palette_t sdl_vm_palette;
|
||||
static my_SDL_PixelFormat_t sdl_vm_pixelformal;
|
||||
static my_SDL_Surface_t sdl_vm_surface;
|
||||
static void* wrapSurface(void* s)
|
||||
{
|
||||
if(!s) return s;
|
||||
if(s==&sdl_vm_surface) {
|
||||
my_SDL_Surface_32_t* src = s;
|
||||
// refressh surface...
|
||||
sdl1_videomode_org->h = src->h;
|
||||
sdl1_videomode_org->w = src->w;
|
||||
sdl1_videomode_org->pitch = src->pitch;
|
||||
sdl1_videomode_org->flags = src->flags;
|
||||
sdl1_videomode_org->locked = src->locked;
|
||||
sdl1_videomode_org->refcount = src->refcount;
|
||||
sdl1_videomode_org->offset = src->offset;
|
||||
sdl1_videomode_org->unused1 = src->unused1;
|
||||
sdl1_videomode_org->format_version = src->format_version;
|
||||
sdl1_videomode_org->pixels = from_ptrv(src->pixels);
|
||||
sdl1_videomode_org->map = from_ptrv(src->map);
|
||||
sdl1_videomode_org->clip_rect.x = src->clip_rect.x;
|
||||
sdl1_videomode_org->clip_rect.y = src->clip_rect.y;
|
||||
sdl1_videomode_org->clip_rect.h = src->clip_rect.h;
|
||||
sdl1_videomode_org->clip_rect.w = src->clip_rect.w;
|
||||
return sdl1_videomode_org;
|
||||
}
|
||||
inplace_SDL_Surface_to_64(s);
|
||||
return s;
|
||||
}
|
||||
static void* unwrapSurface(void* s)
|
||||
{
|
||||
if(!s) return s;
|
||||
if(s==&sdl_vm_surface) {
|
||||
my_SDL_Surface_32_t* dst = s;
|
||||
// refressh surface...
|
||||
dst->h = sdl1_videomode_org->h;
|
||||
dst->w = sdl1_videomode_org->w;
|
||||
dst->pitch = sdl1_videomode_org->pitch;
|
||||
dst->flags = sdl1_videomode_org->flags;
|
||||
dst->locked = sdl1_videomode_org->locked;
|
||||
dst->refcount = sdl1_videomode_org->refcount;
|
||||
dst->offset = sdl1_videomode_org->offset;
|
||||
dst->unused1 = sdl1_videomode_org->unused1;
|
||||
dst->format_version = sdl1_videomode_org->format_version;
|
||||
dst->pixels = to_ptrv(sdl1_videomode_org->pixels);
|
||||
dst->map = to_ptrv(sdl1_videomode_org->map);
|
||||
dst->clip_rect.x = sdl1_videomode_org->clip_rect.x;
|
||||
dst->clip_rect.y = sdl1_videomode_org->clip_rect.y;
|
||||
dst->clip_rect.h = sdl1_videomode_org->clip_rect.h;
|
||||
dst->clip_rect.w = sdl1_videomode_org->clip_rect.w;
|
||||
return s;
|
||||
}
|
||||
inplace_SDL_Surface_to_32(s);
|
||||
return s;
|
||||
}
|
||||
|
||||
EXPORT void my32_SDL_Quit()
|
||||
{
|
||||
sdl1_videomode_org = NULL;
|
||||
my->SDL_Quit();
|
||||
}
|
||||
|
||||
EXPORT void* my32_SDL_SetVideoMode(int width, int height, int bpp, uint32_t flags)
|
||||
{
|
||||
my_SDL_Surface_t* ret = my->SDL_SetVideoMode(width, height, bpp, flags);
|
||||
sdl1_videomode_org = ret;
|
||||
memcpy(&sdl_vm_surface, ret, sizeof(sdl_vm_surface));
|
||||
if(ret->format) {
|
||||
memcpy(&sdl_vm_pixelformal, ret->format, sizeof(sdl_vm_pixelformal));
|
||||
if(ret->format->palette) {
|
||||
memcpy(&sdl_vm_palette, ret->format->palette, sizeof(sdl_vm_palette));
|
||||
sdl_vm_pixelformal.palette = &sdl_vm_palette;
|
||||
}
|
||||
sdl_vm_surface.format = &sdl_vm_pixelformal;
|
||||
}
|
||||
inplace_SDL_Surface_to_32(&sdl_vm_surface);
|
||||
return &sdl_vm_surface;
|
||||
}
|
||||
|
||||
EXPORT int my32_SDL_LockSurface(void* s)
|
||||
{
|
||||
int ret = my->SDL_LockSurface(wrapSurface(s));
|
||||
unwrapSurface(s);
|
||||
return ret;
|
||||
}
|
||||
|
||||
EXPORT void my32_SDL_UnlockSurface(void* s)
|
||||
{
|
||||
my->SDL_UnlockSurface(wrapSurface(s));
|
||||
unwrapSurface(s);
|
||||
}
|
||||
|
||||
EXPORT int my32_SDL_Flip(void* s)
|
||||
{
|
||||
int ret = my->SDL_Flip(wrapSurface(s));
|
||||
unwrapSurface(s);
|
||||
return ret;
|
||||
}
|
||||
|
||||
EXPORT int my32_SDL_PollEvent(my_SDL_Event_32_t* evt)
|
||||
{
|
||||
my_SDL_Event_t event;
|
||||
int ret = my->SDL_PollEvent(evt?(&event):NULL);
|
||||
if(ret && evt) {
|
||||
convert_SDL_Event_to_32(evt, &event);
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
//EXPORT int32_t my32_SDL_GetWMInfo(x64emu_t* emu, void* p)
|
||||
//{
|
||||
// // does SDL_SysWMinfo needs alignment?
|
||||
// int ret = my->SDL_GetWMInfo(p);
|
||||
// my32_SDL_SysWMinfo *info = (my32_SDL_SysWMinfo*)p;
|
||||
// if(info->info.x11.lock_func)
|
||||
// info->info.x11.lock_func = (void*)AddCheckBridge(emu->context->system, vFv_32, info->info.x11.lock_func, 0, NULL);
|
||||
// if(info->info.x11.unlock_func)
|
||||
// info->info.x11.unlock_func = (void*)AddCheckBridge(emu->context->system, vFv_32, info->info.x11.unlock_func, 0, NULL);
|
||||
// return ret;
|
||||
//}
|
||||
|
||||
//#define CUSTOM_INIT \
|
||||
// box64->sdl1allocrw = my->SDL_AllocRW; \
|
||||
// box64->sdl1freerw = my->SDL_FreeRW;
|
||||
|
||||
#define NEEDED_LIBS "libm.so.6", "libdl.so.2", "librt.so.1"
|
||||
|
||||
//#define CUSTOM_FINI \
|
||||
// my32_context->sdl1allocrw = NULL; \
|
||||
// my32_context->sdl1freerw = NULL;
|
||||
|
||||
#include "wrappedlib_init32.h"
|
238
src/wrapped32/wrappedsdl1_private.h
Normal file
238
src/wrapped32/wrappedsdl1_private.h
Normal file
@ -0,0 +1,238 @@
|
||||
#if !(defined(GO) && defined(GOM) && defined(GO2) && defined(DATA))
|
||||
#error Meh...
|
||||
#endif
|
||||
|
||||
// _fini
|
||||
// _init
|
||||
//GOM(SDL_AddTimer, pFEupp)
|
||||
//GO(SDL_AllocRW, pFv) // no need to use a my_ version here
|
||||
//GO(SDL_CDClose, vFp)
|
||||
//GO(SDL_CDEject, iFp)
|
||||
//GO(SDL_CDName, pFi)
|
||||
//GO(SDL_CDNumDrives, iFv)
|
||||
//GO(SDL_CDOpen, pFi)
|
||||
//GO(SDL_CDPause, iFp)
|
||||
//GO(SDL_CDPlay, iFpii)
|
||||
//GO(SDL_CDPlayTracks, iFpiiii)
|
||||
//GO(SDL_CDResume, iFp)
|
||||
//GO(SDL_CDStatus, iFp)
|
||||
//GO(SDL_CDStop, iFp)
|
||||
//GO(SDL_ClearError, vFv)
|
||||
//GO(SDL_CondBroadcast, iFp)
|
||||
//GO(SDL_CondSignal, iFp)
|
||||
//GO(SDL_CondWait, iFpp)
|
||||
//GO(SDL_CondWaitTimeout, iFppu)
|
||||
//GO(SDL_ConvertSurface, pFppu)
|
||||
//GO(SDL_CreateCond, pFv)
|
||||
//GO(SDL_CreateCursor, pFppiiii)
|
||||
//GO(SDL_CreateMutex, pFv)
|
||||
//GO(SDL_CreateRGBSurface, pFuiiiuuuu)
|
||||
//GO(SDL_CreateRGBSurfaceFrom, pFpiiiiuuuu)
|
||||
GO(SDL_CreateSemaphore, pFu)
|
||||
GOM(SDL_CreateThread, pFEpp)
|
||||
//GO(SDL_CreateYUVOverlay, pFiiup)
|
||||
//GO(SDL_Delay, vFu)
|
||||
//GO(SDL_DestroyCond, vFp)
|
||||
//GO(SDL_DestroyMutex, vFp)
|
||||
//GO(SDL_DestroySemaphore, vFp)
|
||||
//GO(SDL_DisplayFormat, pFp)
|
||||
//GO(SDL_DisplayFormatAlpha, pFp)
|
||||
//GO(SDL_DisplayYUVOverlay, iFpp)
|
||||
//GO(SDL_EnableKeyRepeat, iFii)
|
||||
//GO(SDL_EnableUNICODE, iFi)
|
||||
//GO(SDL_Error, vFu)
|
||||
//GO(SDL_EventState, CFCi)
|
||||
//GO(SDL_FillRect, iFppu)
|
||||
GOM(SDL_Flip, iFp) //%noE
|
||||
//GO(SDL_FreeCursor, vFp)
|
||||
//GO(SDL_FreeRW, vFp)
|
||||
//GO(SDL_FreeSurface, vFp)
|
||||
//GO(SDL_FreeYUVOverlay, vFp)
|
||||
GO(SDL_GL_GetAttribute, iFup)
|
||||
GOM(SDL_GL_GetProcAddress, pFEp)
|
||||
GO(SDL_GL_LoadLibrary, iFp)
|
||||
GO(SDL_GL_Lock, vFv)
|
||||
GO(SDL_GL_SetAttribute, iFui)
|
||||
GO(SDL_GL_SwapBuffers, vFv)
|
||||
//GO(SDL_GL_Unlock, vFv)
|
||||
//GO(SDL_GL_UpdateRects, vFip)
|
||||
//GO(SDL_GetAppState, CFv)
|
||||
//GO(SDL_GetClipRect, vFpp)
|
||||
//GO(SDL_GetCursor, pFv)
|
||||
//GO(SDL_GetError, pFv)
|
||||
//GOM(SDL_GetEventFilter, pFEv)
|
||||
//GO(SDL_GetGammaRamp, iFppp)
|
||||
//GO(SDL_GetKeyName, pFu)
|
||||
//GO(SDL_GetKeyRepeat, vFpp)
|
||||
GO(SDL_GetKeyState, pFp)
|
||||
//GO(SDL_GetModState, uFv)
|
||||
//GO(SDL_GetMouseState, uFpp)
|
||||
//GO(SDL_GetRGB, vFupppp)
|
||||
//GO(SDL_GetRGBA, vFuppppp)
|
||||
//GO(SDL_GetRelativeMouseState, CFpp)
|
||||
//GO(SDL_GetThreadID, uFp)
|
||||
GO(SDL_GetTicks, uFv)
|
||||
//GO(SDL_GetVideoInfo, pFv)
|
||||
//GO(SDL_GetVideoSurface, pFv)
|
||||
//GOM(SDL_GetWMInfo, iFEp)
|
||||
GOM(SDL_Has3DNow, iFv) //%noE
|
||||
GOM(SDL_Has3DNowExt, iFv) //%noE
|
||||
GOM(SDL_HasAltiVec, iFv) //%noE
|
||||
GOM(SDL_HasMMX, iFv) //%noE
|
||||
GOM(SDL_HasMMXExt, iFv) //%noE
|
||||
GOM(SDL_HasRDTSC, iFv) //%noE
|
||||
GOM(SDL_HasSSE, iFv) //%noE
|
||||
GOM(SDL_HasSSE2, iFv) //%noE
|
||||
GO(SDL_Init, iFu)
|
||||
//GO(SDL_InitQuickDraw, vFp)
|
||||
GO(SDL_InitSubSystem, iFu)
|
||||
GO(SDL_JoystickClose, vFp)
|
||||
GO(SDL_JoystickEventState, iFi)
|
||||
GO(SDL_JoystickGetAxis, wFpi)
|
||||
GO(SDL_JoystickGetBall, iFpipp)
|
||||
GO(SDL_JoystickGetButton, CFpi)
|
||||
GO(SDL_JoystickGetHat, uFpi)
|
||||
GO(SDL_JoystickIndex, iFp)
|
||||
GO(SDL_JoystickName, pFi)
|
||||
GO(SDL_JoystickNumAxes, iFp)
|
||||
GO(SDL_JoystickNumBalls, iFp)
|
||||
GO(SDL_JoystickNumButtons, iFp)
|
||||
GO(SDL_JoystickNumHats, iFp)
|
||||
GO(SDL_JoystickOpen, pFi)
|
||||
GO(SDL_JoystickOpened, iFi)
|
||||
GO(SDL_JoystickUpdate, vFv)
|
||||
GOM(SDL_KillThread, vFEp)
|
||||
//GO(SDL_Linked_Version, pFv)
|
||||
//GO(SDL_ListModes, pFpu)
|
||||
//GOM(SDL_LoadBMP_RW, pFEpi)
|
||||
GOM(SDL_LoadFunction, pFEpp)
|
||||
GOM(SDL_LoadObject, pFEp)
|
||||
GOM(SDL_LockSurface, iFp) //%noE
|
||||
//GO(SDL_LockYUVOverlay, iFp)
|
||||
//GO(SDL_LowerBlit, iFpppp)
|
||||
//GO(SDL_MapRGB, uFpCCC)
|
||||
//GO(SDL_MapRGBA, uFpCCCC)
|
||||
GO(SDL_NumJoysticks, iFv)
|
||||
//GO(SDL_PeepEvents, iFpiuu)
|
||||
GOM(SDL_PollEvent, iFp) //%noE
|
||||
//GO(SDL_PumpEvents, vFv)
|
||||
//GO(SDL_PushEvent, iFp)
|
||||
GOM(SDL_Quit, vFv) //%noE
|
||||
GO(SDL_QuitSubSystem, vFu)
|
||||
//GOM(SDL_RWFromConstMem, pFEpi)
|
||||
//GOM(SDL_RWFromFP, pFEpi)
|
||||
//GOM(SDL_RWFromFile, pFEpp)
|
||||
//GOM(SDL_RWFromMem, pFEpi)
|
||||
//GOM(SDL_ReadBE16, uFEp)
|
||||
//GOM(SDL_ReadBE32, uFEp)
|
||||
//GOM(SDL_ReadBE64, UFEp)
|
||||
//GOM(SDL_ReadLE16, uFEp)
|
||||
//GOM(SDL_ReadLE32, uFEp)
|
||||
//GOM(SDL_ReadLE64, UFEp)
|
||||
//GO(SDL_RegisterApp, iFpup)
|
||||
//GOM(SDL_RemoveTimer, iFEp)
|
||||
//GOM(SDL_SaveBMP_RW, iFEppi)
|
||||
GO(SDL_SemPost, iFp)
|
||||
GO(SDL_SemTryWait, iFp)
|
||||
GO(SDL_SemValue, uFp)
|
||||
GO(SDL_SemWait, iFp)
|
||||
GO(SDL_SemWaitTimeout, iFpu)
|
||||
GO(SDL_SetAlpha, iFpuC)
|
||||
//GO(SDL_SetClipRect, uFpp)
|
||||
//GO(SDL_SetColorKey, iFpuu)
|
||||
//GO(SDL_SetColors, iFppii)
|
||||
//GO(SDL_SetCursor, vFp)
|
||||
//GO(SDL_SetError, vFpppppp) // use ..., so putting arbitrary number of arguments...
|
||||
//GOM(SDL_SetEventFilter, vFEp)
|
||||
GO(SDL_SetGamma, iFfff)
|
||||
//GO(SDL_SetGammaRamp, iFppp)
|
||||
GO(SDL_SetModState, vFu)
|
||||
//GO(SDL_SetModuleHandle, vFp)
|
||||
//GO(SDL_SetPalette, iFpipii)
|
||||
//GOM(SDL_SetTimer, iFEup)
|
||||
GOM(SDL_SetVideoMode, pFiiiu) //%noE
|
||||
GO(SDL_ShowCursor, iFi)
|
||||
//GO(SDL_SoftStretch, iFpppp)
|
||||
//GO(SDL_ThreadID, uFv)
|
||||
//GOM(SDL_UnloadObject, vFEp)
|
||||
GOM(SDL_UnlockSurface, vFp) //%noE
|
||||
//GO(SDL_UnlockYUVOverlay, vFp)
|
||||
//GO(SDL_UnregisterApp, vFv)
|
||||
//GO(SDL_UpdateRect, vFpiiuu)
|
||||
//GO(SDL_UpdateRects, vFpip)
|
||||
//GO(SDL_UpperBlit, iFpppp)
|
||||
//GO(SDL_VideoDriverName, pFpi)
|
||||
//GO(SDL_VideoInit, iFpu)
|
||||
//GO(SDL_VideoModeOK, iFiiiu)
|
||||
GO(SDL_VideoQuit, vFv)
|
||||
//GO(SDL_WM_GetCaption, vFpp)
|
||||
GO(SDL_WM_GrabInput, iFi)
|
||||
GO(SDL_WM_IconifyWindow, iFv)
|
||||
GO(SDL_WM_SetCaption, vFpp)
|
||||
//GO(SDL_WM_SetIcon, vFpp)
|
||||
//GO(SDL_WM_ToggleFullScreen, iFp)
|
||||
//GO(SDL_WaitEvent, iFp)
|
||||
//GO(SDL_WaitThread, vFpp)
|
||||
GO(SDL_WarpMouse, vFWW)
|
||||
GO(SDL_WasInit, uFu)
|
||||
//GOM(SDL_WriteBE16, uFEpW)
|
||||
//GOM(SDL_WriteBE32, uFEpu)
|
||||
//GOM(SDL_WriteBE64, uFEpU)
|
||||
//GOM(SDL_WriteLE16, uFEpW)
|
||||
//GOM(SDL_WriteLE32, uFEpu)
|
||||
//GOM(SDL_WriteLE64, uFEpU)
|
||||
//GO(SDL_framerateDelay, uFp)
|
||||
//GO(SDL_getFramecount, iFp)
|
||||
//GO(SDL_getFramerate, iFp)
|
||||
//GO(SDL_iconv, LFppppp)
|
||||
//GO(SDL_iconv_close, iFp)
|
||||
//GO(SDL_iconv_open, pFpp)
|
||||
//GO(SDL_iconv_string, pFpppL)
|
||||
//GO(SDL_initFramerate, vFp)
|
||||
//GO(SDL_lltoa, pFlpi)
|
||||
//GO(SDL_ltoa, pFlpi)
|
||||
//GO(SDL_main, iFip)
|
||||
//GO(SDL_memcmp, iFppu)
|
||||
//GO(SDL_mutexP, iFp)
|
||||
//GO(SDL_mutexV, iFp)
|
||||
//GO(SDL_revcpy, pFppL)
|
||||
//GO(SDL_setFramerate, iFpu)
|
||||
//GO(SDL_snprintf, iFpupppppp) // use ...
|
||||
//GO(SDL_sscanf, iFppppppp) // use ...
|
||||
//GO(SDL_strcasecmp, iFpp)
|
||||
//GO(SDL_strchr, pFpi)
|
||||
//GO(SDL_strcmp, iFpp)
|
||||
//GO(SDL_strdup, pFp)
|
||||
//GO(SDL_strlcat, LFppL)
|
||||
//GO(SDL_strlcpy, uFppu)
|
||||
//GO(SDL_strlen, uFp)
|
||||
//GO(SDL_strlwr, pFp)
|
||||
//GO(SDL_strncasecmp, iFppu)
|
||||
//GO(SDL_strncmp, iFppu)
|
||||
//GO(SDL_strrchr, pFpi)
|
||||
//GO(SDL_strrev, pFp)
|
||||
//GO(SDL_strstr, pFpp)
|
||||
//GO(SDL_strtod, dFpp)
|
||||
//GO(SDL_strtol, iFppi)
|
||||
//GO(SDL_strtoll, IFppi)
|
||||
//GO(SDL_strtoul, uFppi)
|
||||
//GO(SDL_strtoull, UFppi)
|
||||
//GO(SDL_strupr, pFp)
|
||||
//GO(SDL_ulltoa, pFLpi)
|
||||
//GO(SDL_ultoa, pFLpi)
|
||||
//GOM(SDL_vsnprintf, iFpupV)
|
||||
GOM(SDL_OpenAudio, iFEpp)
|
||||
GO(SDL_LockAudio, vFv)
|
||||
GO(SDL_UnlockAudio, vFv)
|
||||
GO(SDL_PauseAudio, vFi)
|
||||
GO(SDL_GetAudioStatus, uFv)
|
||||
//GO(SDL_LoadWAV, pFpppp)
|
||||
//GO(SDL_FreeWAV, vFp)
|
||||
//GOM(SDL_LoadWAV_RW, pFEpippp)
|
||||
//GO(SDL_BuildAudioCVT, iFpWCiWCi)
|
||||
//GO(SDL_ConvertAudio, iFp)
|
||||
//GO(SDL_AudioInit, iFp)
|
||||
GO(SDL_AudioQuit, vFv)
|
||||
//GO(SDL_MixAudio, vFppui)
|
||||
GO(SDL_CloseAudio, vFv)
|
||||
//GO(SDL_AudioDriverName, pFpi)
|
42
src/wrapped32/wrappercallback32.h
Normal file
42
src/wrapped32/wrappercallback32.h
Normal file
@ -0,0 +1,42 @@
|
||||
#define TYPENAME3(N,M) N##M
|
||||
#define TYPENAME2(N,M) TYPENAME3(N,M)
|
||||
#define TYPENAME(N) TYPENAME2(LIBNAME, _my_t)
|
||||
|
||||
typedef struct TYPENAME2(LIBNAME, _my_s) {
|
||||
// functions
|
||||
#define GO(A, B) B A;
|
||||
SUPER()
|
||||
#undef GO
|
||||
#ifdef ADDED_STRUCT
|
||||
ADDED_STRUCT()
|
||||
#endif
|
||||
} TYPENAME(LIBNAME);
|
||||
|
||||
static library_t* my_lib = NULL;
|
||||
static TYPENAME(LIBNAME) TYPENAME2(my_, LIBNAME) = {0};
|
||||
static TYPENAME(LIBNAME) * const my = &TYPENAME2(my_, LIBNAME);
|
||||
|
||||
static void getMy(library_t* lib)
|
||||
{
|
||||
#define GO(A, W) my->A = (W)dlsym(lib->w.lib, #A);
|
||||
SUPER()
|
||||
#undef GO
|
||||
my_lib = lib;
|
||||
#ifdef ADDED_INIT
|
||||
ADDED_INIT()
|
||||
#endif
|
||||
}
|
||||
|
||||
static void freeMy()
|
||||
{
|
||||
#ifdef ADDED_FINI
|
||||
ADDED_FINI()
|
||||
#endif
|
||||
my_lib = NULL;
|
||||
}
|
||||
|
||||
#define HAS_MY
|
||||
|
||||
#ifndef ADDED_SUPER
|
||||
#undef SUPER
|
||||
#endif
|
Loading…
Reference in New Issue
Block a user