diff --git a/src/wrapped32/generated/functions_list.txt b/src/wrapped32/generated/functions_list.txt index 1c39424b5..7a57cee34 100644 --- a/src/wrapped32/generated/functions_list.txt +++ b/src/wrapped32/generated/functions_list.txt @@ -336,6 +336,7 @@ #() iFhpp -> iFhpp #() iFSIi -> iFSIi #() iFSli -> iFSli +#() iFXii -> iFXii #() iFXip -> iFXip #() iFXuu -> iFXuu #() iFXLl -> iFXLl @@ -364,6 +365,7 @@ #() lFlpi -> lFlpi #() lFpLL -> lFpLL #() lFppL -> lFppL +#() LFEpi -> LFEpi #() LFpii -> LFpii #() LFpip -> LFpip #() LFppL -> LFppL @@ -508,6 +510,7 @@ #() iFEipV -> iFEipV #() iFEpip -> iFEpip #() iFEpui -> iFEpui +#() iFEpuu -> iFEpuu #() iFEpup -> iFEpup #() iFEpLi -> iFEpLi #() iFEppL -> iFEppL @@ -799,6 +802,8 @@ #() iFEuppLp -> iFEuppLp #() iFEpiLpp -> iFEpiLpp #() iFEplluu -> iFEplluu +#() iFEppipp -> iFEppipp +#() iFEppllp -> iFEppllp #() iFEpppup -> iFEpppup #() iFEXLilp -> iFEXLilp #() iFEXpiup -> iFEXpiup @@ -806,6 +811,7 @@ #() iFuiiuup -> iFuiiuup #() iFpiippp -> iFpiippp #() iFppiiii -> iFppiiii +#() iFXiippp -> iFXiippp #() iFXLiiiL -> iFXLiiiL #() iFXLpppp -> iFXLpppp #() iFXpIppp -> iFXpIppp @@ -1043,10 +1049,14 @@ wrappedfreetype: - FT_Get_Char_Index - iFpui: - FT_Load_Glyph +- iFpuu: + - FT_Set_Pixel_Sizes - iFpplp: - FT_New_Face - iFplluu: - FT_Set_Char_Size +- iFppllp: + - FT_New_Memory_Face wrappedldlinux: - pFv: - ___tls_get_addr @@ -1065,6 +1075,7 @@ wrappedlibc: - iFL: - iFp: - getifaddrs + - sysinfo - iFh: - getwc - iFO: @@ -1438,6 +1449,9 @@ wrappedlibx11: - XFilterEvent - iFXp: - XNextEvent + - XPeekEvent +- LFpi: + - XLookupKeysym - pFpV: - XCreateIC - pFXp: @@ -1457,6 +1471,8 @@ wrappedlibx11: - XSetWMProtocols - iFXppp: - XIfEvent +- iFppipp: + - XLookupString - iFXLilp: - XSendEvent - iFXpiup: diff --git a/src/wrapped32/generated/wrappedfreetypetypes32.h b/src/wrapped32/generated/wrappedfreetypetypes32.h index 217794259..432b63434 100644 --- a/src/wrapped32/generated/wrappedfreetypetypes32.h +++ b/src/wrapped32/generated/wrappedfreetypetypes32.h @@ -16,8 +16,10 @@ typedef void (*vFpp_t)(void*, void*); typedef int32_t (*iFpu_t)(void*, uint32_t); typedef uint32_t (*uFpL_t)(void*, uintptr_t); typedef int32_t (*iFpui_t)(void*, uint32_t, int32_t); +typedef int32_t (*iFpuu_t)(void*, uint32_t, uint32_t); typedef int32_t (*iFpplp_t)(void*, void*, intptr_t, void*); typedef int32_t (*iFplluu_t)(void*, intptr_t, intptr_t, uint32_t, uint32_t); +typedef int32_t (*iFppllp_t)(void*, void*, intptr_t, intptr_t, void*); #define SUPER() ADDED_FUNCTIONS() \ GO(FT_Done_Face, iFp_t) \ @@ -25,7 +27,9 @@ typedef int32_t (*iFplluu_t)(void*, intptr_t, intptr_t, uint32_t, uint32_t); GO(FT_Render_Glyph, iFpu_t) \ GO(FT_Get_Char_Index, uFpL_t) \ GO(FT_Load_Glyph, iFpui_t) \ + GO(FT_Set_Pixel_Sizes, iFpuu_t) \ GO(FT_New_Face, iFpplp_t) \ - GO(FT_Set_Char_Size, iFplluu_t) + GO(FT_Set_Char_Size, iFplluu_t) \ + GO(FT_New_Memory_Face, iFppllp_t) #endif // __wrappedfreetypeTYPES32_H_ diff --git a/src/wrapped32/generated/wrappedlibctypes32.h b/src/wrapped32/generated/wrappedlibctypes32.h index b3c7f7ae5..5e517840e 100644 --- a/src/wrapped32/generated/wrappedlibctypes32.h +++ b/src/wrapped32/generated/wrappedlibctypes32.h @@ -102,6 +102,7 @@ typedef void* (*pFiiiiiiiiilt_t)(int32_t, int32_t, int32_t, int32_t, int32_t, in GO(freeaddrinfo, vFp_t) \ GO(__close_nocancel, iFi_t) \ GO(getifaddrs, iFp_t) \ + GO(sysinfo, iFp_t) \ GO(getwc, iFh_t) \ GO(atol, lFp_t) \ GO(ftell, lFS_t) \ diff --git a/src/wrapped32/generated/wrappedlibx11types32.h b/src/wrapped32/generated/wrappedlibx11types32.h index 9790f2891..7ca4ec084 100644 --- a/src/wrapped32/generated/wrappedlibx11types32.h +++ b/src/wrapped32/generated/wrappedlibx11types32.h @@ -16,6 +16,7 @@ typedef int32_t (*iFX_t)(void*); typedef void* (*pFp_t)(void*); typedef int32_t (*iFpL_t)(void*, uintptr_t); typedef int32_t (*iFXp_t)(void*, void*); +typedef uintptr_t (*LFpi_t)(void*, int32_t); typedef void* (*pFpV_t)(void*, ...); typedef void* (*pFXp_t)(void*, void*); typedef void (*vFXLp_t)(void*, uintptr_t, void*); @@ -25,6 +26,7 @@ typedef int32_t (*iFXLp_t)(void*, uintptr_t, void*); typedef uintptr_t (*LFXii_t)(void*, int32_t, int32_t); typedef int32_t (*iFXLpi_t)(void*, uintptr_t, void*, int32_t); typedef int32_t (*iFXppp_t)(void*, void*, void*, void*); +typedef int32_t (*iFppipp_t)(void*, void*, int32_t, void*, void*); typedef int32_t (*iFXLilp_t)(void*, uintptr_t, int32_t, intptr_t, void*); typedef int32_t (*iFXpiup_t)(void*, void*, int32_t, uint32_t, void*); typedef int32_t (*iFXpppp_t)(void*, void*, void*, void*, void*); @@ -48,6 +50,8 @@ typedef uintptr_t (*LFXLiiuuuiupLp_t)(void*, uintptr_t, int32_t, int32_t, uint32 GO(XSetErrorHandler, pFp_t) \ GO(XFilterEvent, iFpL_t) \ GO(XNextEvent, iFXp_t) \ + GO(XPeekEvent, iFXp_t) \ + GO(XLookupKeysym, LFpi_t) \ GO(XCreateIC, pFpV_t) \ GO(XListExtensions, pFXp_t) \ GO(XSetWMNormalHints, vFXLp_t) \ @@ -58,6 +62,7 @@ typedef uintptr_t (*LFXLiiuuuiupLp_t)(void*, uintptr_t, int32_t, int32_t, uint32 GO(XGetPixel, LFXii_t) \ GO(XSetWMProtocols, iFXLpi_t) \ GO(XIfEvent, iFXppp_t) \ + GO(XLookupString, iFppipp_t) \ GO(XSendEvent, iFXLilp_t) \ GO(Xutf8TextListToTextProperty, iFXpiup_t) \ GO(XQueryExtension, iFXpppp_t) \ diff --git a/src/wrapped32/generated/wrapper32.c b/src/wrapped32/generated/wrapper32.c index 3af71f8ce..8f7be2836 100644 --- a/src/wrapped32/generated/wrapper32.c +++ b/src/wrapped32/generated/wrapper32.c @@ -426,6 +426,7 @@ typedef int32_t (*iFhpL_t)(uintptr_t, void*, uintptr_t); typedef int32_t (*iFhpp_t)(uintptr_t, void*, void*); typedef int32_t (*iFSIi_t)(void*, int64_t, int32_t); typedef int32_t (*iFSli_t)(void*, intptr_t, int32_t); +typedef int32_t (*iFXii_t)(void*, int32_t, int32_t); typedef int32_t (*iFXip_t)(void*, int32_t, void*); typedef int32_t (*iFXuu_t)(void*, uint32_t, uint32_t); typedef int32_t (*iFXLl_t)(void*, uintptr_t, intptr_t); @@ -454,6 +455,7 @@ typedef intptr_t (*lFipL_t)(int32_t, void*, uintptr_t); typedef intptr_t (*lFlpi_t)(intptr_t, void*, int32_t); typedef intptr_t (*lFpLL_t)(void*, uintptr_t, uintptr_t); typedef intptr_t (*lFppL_t)(void*, void*, uintptr_t); +typedef uintptr_t (*LFEpi_t)(x64emu_t*, void*, int32_t); typedef uintptr_t (*LFpii_t)(void*, int32_t, int32_t); typedef uintptr_t (*LFpip_t)(void*, int32_t, void*); typedef uintptr_t (*LFppL_t)(void*, void*, uintptr_t); @@ -598,6 +600,7 @@ typedef int32_t (*iFEipp_t)(x64emu_t*, int32_t, void*, void*); typedef int32_t (*iFEipV_t)(x64emu_t*, int32_t, void*, void*); typedef int32_t (*iFEpip_t)(x64emu_t*, void*, int32_t, void*); typedef int32_t (*iFEpui_t)(x64emu_t*, void*, uint32_t, int32_t); +typedef int32_t (*iFEpuu_t)(x64emu_t*, void*, uint32_t, uint32_t); typedef int32_t (*iFEpup_t)(x64emu_t*, void*, uint32_t, void*); typedef int32_t (*iFEpLi_t)(x64emu_t*, void*, uintptr_t, int32_t); typedef int32_t (*iFEppL_t)(x64emu_t*, void*, void*, uintptr_t); @@ -889,6 +892,8 @@ typedef int32_t (*iFEuppup_t)(x64emu_t*, uint32_t, void*, void*, uint32_t, void* typedef int32_t (*iFEuppLp_t)(x64emu_t*, uint32_t, void*, void*, uintptr_t, void*); typedef int32_t (*iFEpiLpp_t)(x64emu_t*, void*, int32_t, uintptr_t, void*, void*); typedef int32_t (*iFEplluu_t)(x64emu_t*, void*, intptr_t, intptr_t, uint32_t, uint32_t); +typedef int32_t (*iFEppipp_t)(x64emu_t*, void*, void*, int32_t, void*, void*); +typedef int32_t (*iFEppllp_t)(x64emu_t*, void*, void*, intptr_t, intptr_t, void*); typedef int32_t (*iFEpppup_t)(x64emu_t*, void*, void*, void*, uint32_t, void*); typedef int32_t (*iFEXLilp_t)(x64emu_t*, void*, uintptr_t, int32_t, intptr_t, void*); typedef int32_t (*iFEXpiup_t)(x64emu_t*, void*, void*, int32_t, uint32_t, void*); @@ -896,6 +901,7 @@ typedef int32_t (*iFEXpppp_t)(x64emu_t*, void*, void*, void*, void*, void*); typedef int32_t (*iFuiiuup_t)(uint32_t, int32_t, int32_t, uint32_t, uint32_t, void*); typedef int32_t (*iFpiippp_t)(void*, int32_t, int32_t, void*, void*, void*); typedef int32_t (*iFppiiii_t)(void*, void*, int32_t, int32_t, int32_t, int32_t); +typedef int32_t (*iFXiippp_t)(void*, int32_t, int32_t, void*, void*, void*); typedef int32_t (*iFXLiiiL_t)(void*, uintptr_t, int32_t, int32_t, int32_t, uintptr_t); typedef int32_t (*iFXLpppp_t)(void*, uintptr_t, void*, void*, void*, void*); typedef int32_t (*iFXpIppp_t)(void*, void*, int64_t, void*, void*, void*); @@ -1459,6 +1465,7 @@ void iFhpL_32(x64emu_t *emu, uintptr_t fcn) { iFhpL_t fn = (iFhpL_t)fcn; R_EAX = void iFhpp_32(x64emu_t *emu, uintptr_t fcn) { iFhpp_t fn = (iFhpp_t)fcn; R_EAX = fn(from_hash(from_ptri(ptr_t, R_ESP + 4)), from_ptriv(R_ESP + 8), from_ptriv(R_ESP + 12)); } void iFSIi_32(x64emu_t *emu, uintptr_t fcn) { iFSIi_t fn = (iFSIi_t)fcn; R_EAX = fn(io_convert32(from_ptriv(R_ESP + 4)), from_ptri(int64_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 16)); } void iFSli_32(x64emu_t *emu, uintptr_t fcn) { iFSli_t fn = (iFSli_t)fcn; R_EAX = fn(io_convert32(from_ptriv(R_ESP + 4)), to_long(from_ptri(long_t, R_ESP + 8)), from_ptri(int32_t, R_ESP + 12)); } +void iFXii_32(x64emu_t *emu, uintptr_t fcn) { iFXii_t fn = (iFXii_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), from_ptri(int32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12)); } void iFXip_32(x64emu_t *emu, uintptr_t fcn) { iFXip_t fn = (iFXip_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), from_ptri(int32_t, R_ESP + 8), from_ptriv(R_ESP + 12)); } void iFXuu_32(x64emu_t *emu, uintptr_t fcn) { iFXuu_t fn = (iFXuu_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), from_ptri(uint32_t, R_ESP + 8), from_ptri(uint32_t, R_ESP + 12)); } void iFXLl_32(x64emu_t *emu, uintptr_t fcn) { iFXLl_t fn = (iFXLl_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), to_ulong(from_ptri(ulong_t, R_ESP + 8)), to_long(from_ptri(long_t, R_ESP + 12))); } @@ -1487,6 +1494,7 @@ void lFipL_32(x64emu_t *emu, uintptr_t fcn) { lFipL_t fn = (lFipL_t)fcn; R_EAX = void lFlpi_32(x64emu_t *emu, uintptr_t fcn) { lFlpi_t fn = (lFlpi_t)fcn; R_EAX = to_long(fn(to_long(from_ptri(long_t, R_ESP + 4)), from_ptriv(R_ESP + 8), from_ptri(int32_t, R_ESP + 12))); } void lFpLL_32(x64emu_t *emu, uintptr_t fcn) { lFpLL_t fn = (lFpLL_t)fcn; R_EAX = to_long(fn(from_ptriv(R_ESP + 4), to_ulong(from_ptri(ulong_t, R_ESP + 8)), to_ulong(from_ptri(ulong_t, R_ESP + 12)))); } void lFppL_32(x64emu_t *emu, uintptr_t fcn) { lFppL_t fn = (lFppL_t)fcn; R_EAX = to_long(fn(from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), to_ulong(from_ptri(ulong_t, R_ESP + 12)))); } +void LFEpi_32(x64emu_t *emu, uintptr_t fcn) { LFEpi_t fn = (LFEpi_t)fcn; R_EAX = to_ulong(fn(emu, from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8))); } void LFpii_32(x64emu_t *emu, uintptr_t fcn) { LFpii_t fn = (LFpii_t)fcn; R_EAX = to_ulong(fn(from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12))); } void LFpip_32(x64emu_t *emu, uintptr_t fcn) { LFpip_t fn = (LFpip_t)fcn; R_EAX = to_ulong(fn(from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8), from_ptriv(R_ESP + 12))); } void LFppL_32(x64emu_t *emu, uintptr_t fcn) { LFppL_t fn = (LFppL_t)fcn; R_EAX = to_ulong(fn(from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), to_ulong(from_ptri(ulong_t, R_ESP + 12)))); } @@ -1631,6 +1639,7 @@ void iFEipp_32(x64emu_t *emu, uintptr_t fcn) { iFEipp_t fn = (iFEipp_t)fcn; R_EA void iFEipV_32(x64emu_t *emu, uintptr_t fcn) { iFEipV_t fn = (iFEipV_t)fcn; R_EAX = fn(emu, from_ptri(int32_t, R_ESP + 4), from_ptriv(R_ESP + 8), from_ptrv(R_ESP + 12)); } void iFEpip_32(x64emu_t *emu, uintptr_t fcn) { iFEpip_t fn = (iFEpip_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8), from_ptriv(R_ESP + 12)); } void iFEpui_32(x64emu_t *emu, uintptr_t fcn) { iFEpui_t fn = (iFEpui_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptri(uint32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12)); } +void iFEpuu_32(x64emu_t *emu, uintptr_t fcn) { iFEpuu_t fn = (iFEpuu_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptri(uint32_t, R_ESP + 8), from_ptri(uint32_t, R_ESP + 12)); } void iFEpup_32(x64emu_t *emu, uintptr_t fcn) { iFEpup_t fn = (iFEpup_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptri(uint32_t, R_ESP + 8), from_ptriv(R_ESP + 12)); } void iFEpLi_32(x64emu_t *emu, uintptr_t fcn) { iFEpLi_t fn = (iFEpLi_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), to_ulong(from_ptri(ulong_t, R_ESP + 8)), from_ptri(int32_t, R_ESP + 12)); } void iFEppL_32(x64emu_t *emu, uintptr_t fcn) { iFEppL_t fn = (iFEppL_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), to_ulong(from_ptri(ulong_t, R_ESP + 12))); } @@ -1922,6 +1931,8 @@ void iFEuppup_32(x64emu_t *emu, uintptr_t fcn) { iFEuppup_t fn = (iFEuppup_t)fcn void iFEuppLp_32(x64emu_t *emu, uintptr_t fcn) { iFEuppLp_t fn = (iFEuppLp_t)fcn; R_EAX = fn(emu, from_ptri(uint32_t, R_ESP + 4), from_ptriv(R_ESP + 8), from_ptriv(R_ESP + 12), to_ulong(from_ptri(ulong_t, R_ESP + 16)), from_ptriv(R_ESP + 20)); } void iFEpiLpp_32(x64emu_t *emu, uintptr_t fcn) { iFEpiLpp_t fn = (iFEpiLpp_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8), to_ulong(from_ptri(ulong_t, R_ESP + 12)), from_ptriv(R_ESP + 16), from_ptriv(R_ESP + 20)); } void iFEplluu_32(x64emu_t *emu, uintptr_t fcn) { iFEplluu_t fn = (iFEplluu_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), to_long(from_ptri(long_t, R_ESP + 8)), to_long(from_ptri(long_t, R_ESP + 12)), from_ptri(uint32_t, R_ESP + 16), from_ptri(uint32_t, R_ESP + 20)); } +void iFEppipp_32(x64emu_t *emu, uintptr_t fcn) { iFEppipp_t fn = (iFEppipp_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptriv(R_ESP + 16), from_ptriv(R_ESP + 20)); } +void iFEppllp_32(x64emu_t *emu, uintptr_t fcn) { iFEppllp_t fn = (iFEppllp_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), to_long(from_ptri(long_t, R_ESP + 12)), to_long(from_ptri(long_t, R_ESP + 16)), from_ptriv(R_ESP + 20)); } void iFEpppup_32(x64emu_t *emu, uintptr_t fcn) { iFEpppup_t fn = (iFEpppup_t)fcn; R_EAX = fn(emu, from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), from_ptriv(R_ESP + 12), from_ptri(uint32_t, R_ESP + 16), from_ptriv(R_ESP + 20)); } void iFEXLilp_32(x64emu_t *emu, uintptr_t fcn) { iFEXLilp_t fn = (iFEXLilp_t)fcn; R_EAX = fn(emu, getDisplay(from_ptriv(R_ESP + 4)), to_ulong(from_ptri(ulong_t, R_ESP + 8)), from_ptri(int32_t, R_ESP + 12), to_long(from_ptri(long_t, R_ESP + 16)), from_ptriv(R_ESP + 20)); } void iFEXpiup_32(x64emu_t *emu, uintptr_t fcn) { iFEXpiup_t fn = (iFEXpiup_t)fcn; R_EAX = fn(emu, getDisplay(from_ptriv(R_ESP + 4)), from_ptriv(R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptri(uint32_t, R_ESP + 16), from_ptriv(R_ESP + 20)); } @@ -1929,6 +1940,7 @@ void iFEXpppp_32(x64emu_t *emu, uintptr_t fcn) { iFEXpppp_t fn = (iFEXpppp_t)fcn void iFuiiuup_32(x64emu_t *emu, uintptr_t fcn) { iFuiiuup_t fn = (iFuiiuup_t)fcn; R_EAX = fn(from_ptri(uint32_t, R_ESP + 4), from_ptri(int32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptri(uint32_t, R_ESP + 16), from_ptri(uint32_t, R_ESP + 20), from_ptriv(R_ESP + 24)); } void iFpiippp_32(x64emu_t *emu, uintptr_t fcn) { iFpiippp_t fn = (iFpiippp_t)fcn; R_EAX = fn(from_ptriv(R_ESP + 4), from_ptri(int32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptriv(R_ESP + 16), from_ptriv(R_ESP + 20), from_ptriv(R_ESP + 24)); } void iFppiiii_32(x64emu_t *emu, uintptr_t fcn) { iFppiiii_t fn = (iFppiiii_t)fcn; R_EAX = fn(from_ptriv(R_ESP + 4), from_ptriv(R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptri(int32_t, R_ESP + 16), from_ptri(int32_t, R_ESP + 20), from_ptri(int32_t, R_ESP + 24)); } +void iFXiippp_32(x64emu_t *emu, uintptr_t fcn) { iFXiippp_t fn = (iFXiippp_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), from_ptri(int32_t, R_ESP + 8), from_ptri(int32_t, R_ESP + 12), from_ptriv(R_ESP + 16), from_ptriv(R_ESP + 20), from_ptriv(R_ESP + 24)); } void iFXLiiiL_32(x64emu_t *emu, uintptr_t fcn) { iFXLiiiL_t fn = (iFXLiiiL_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), to_ulong(from_ptri(ulong_t, R_ESP + 8)), from_ptri(int32_t, R_ESP + 12), from_ptri(int32_t, R_ESP + 16), from_ptri(int32_t, R_ESP + 20), to_ulong(from_ptri(ulong_t, R_ESP + 24))); } void iFXLpppp_32(x64emu_t *emu, uintptr_t fcn) { iFXLpppp_t fn = (iFXLpppp_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), to_ulong(from_ptri(ulong_t, R_ESP + 8)), from_ptriv(R_ESP + 12), from_ptriv(R_ESP + 16), from_ptriv(R_ESP + 20), from_ptriv(R_ESP + 24)); } void iFXpIppp_32(x64emu_t *emu, uintptr_t fcn) { iFXpIppp_t fn = (iFXpIppp_t)fcn; R_EAX = fn(getDisplay(from_ptriv(R_ESP + 4)), from_ptriv(R_ESP + 8), from_ptri(int64_t, R_ESP + 12), from_ptriv(R_ESP + 20), from_ptriv(R_ESP + 24), from_ptriv(R_ESP + 28)); } diff --git a/src/wrapped32/generated/wrapper32.h b/src/wrapped32/generated/wrapper32.h index aa1c8e539..288227735 100644 --- a/src/wrapped32/generated/wrapper32.h +++ b/src/wrapped32/generated/wrapper32.h @@ -377,6 +377,7 @@ void iFhpL_32(x64emu_t *emu, uintptr_t fnc); 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 iFXii_32(x64emu_t *emu, uintptr_t fnc); void iFXip_32(x64emu_t *emu, uintptr_t fnc); void iFXuu_32(x64emu_t *emu, uintptr_t fnc); void iFXLl_32(x64emu_t *emu, uintptr_t fnc); @@ -405,6 +406,7 @@ void lFipL_32(x64emu_t *emu, uintptr_t fnc); void lFlpi_32(x64emu_t *emu, uintptr_t fnc); void lFpLL_32(x64emu_t *emu, uintptr_t fnc); void lFppL_32(x64emu_t *emu, uintptr_t fnc); +void LFEpi_32(x64emu_t *emu, uintptr_t fnc); void LFpii_32(x64emu_t *emu, uintptr_t fnc); void LFpip_32(x64emu_t *emu, uintptr_t fnc); void LFppL_32(x64emu_t *emu, uintptr_t fnc); @@ -549,6 +551,7 @@ void iFEipp_32(x64emu_t *emu, uintptr_t fnc); void iFEipV_32(x64emu_t *emu, uintptr_t fnc); void iFEpip_32(x64emu_t *emu, uintptr_t fnc); void iFEpui_32(x64emu_t *emu, uintptr_t fnc); +void iFEpuu_32(x64emu_t *emu, uintptr_t fnc); void iFEpup_32(x64emu_t *emu, uintptr_t fnc); void iFEpLi_32(x64emu_t *emu, uintptr_t fnc); void iFEppL_32(x64emu_t *emu, uintptr_t fnc); @@ -840,6 +843,8 @@ void iFEuppup_32(x64emu_t *emu, uintptr_t fnc); void iFEuppLp_32(x64emu_t *emu, uintptr_t fnc); void iFEpiLpp_32(x64emu_t *emu, uintptr_t fnc); void iFEplluu_32(x64emu_t *emu, uintptr_t fnc); +void iFEppipp_32(x64emu_t *emu, uintptr_t fnc); +void iFEppllp_32(x64emu_t *emu, uintptr_t fnc); void iFEpppup_32(x64emu_t *emu, uintptr_t fnc); void iFEXLilp_32(x64emu_t *emu, uintptr_t fnc); void iFEXpiup_32(x64emu_t *emu, uintptr_t fnc); @@ -847,6 +852,7 @@ void iFEXpppp_32(x64emu_t *emu, uintptr_t fnc); void iFuiiuup_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 iFXiippp_32(x64emu_t *emu, uintptr_t fnc); void iFXLiiiL_32(x64emu_t *emu, uintptr_t fnc); void iFXLpppp_32(x64emu_t *emu, uintptr_t fnc); void iFXpIppp_32(x64emu_t *emu, uintptr_t fnc); diff --git a/src/wrapped32/wrappedfreetype.c b/src/wrapped32/wrappedfreetype.c index f55bcab5d..20e1cae18 100644 --- a/src/wrapped32/wrappedfreetype.c +++ b/src/wrapped32/wrappedfreetype.c @@ -88,6 +88,15 @@ typedef struct FT_Vector_s long y; } FT_Vector_t; +typedef struct FT_Bitmap_Size_s +{ + short height; + short width; + long size; + long x_ppem; + long y_ppem; +} FT_Bitmap_Size_t; + typedef struct FT_Glyph_Metrics_s { long width; @@ -158,7 +167,7 @@ typedef struct FT_FaceRec_s char* family_name; char* style_name; int num_fixed_sizes; - void* available_sizes; + FT_Bitmap_Size_t* available_sizes; int num_charmaps; void* charmaps; FT_Generic_t generic; @@ -250,6 +259,15 @@ typedef struct FT_Vector_32_s long_t y; } FT_Vector_32_t; +typedef struct FT_Bitmap_Size_32_s +{ + short height; + short width; + long_t size; + long_t x_ppem; + long_t y_ppem; +} FT_Bitmap_Size_32_t; + typedef struct FT_Glyph_Metrics_32_s { long_t width; @@ -316,16 +334,16 @@ typedef struct FT_FaceRec_32_s long_t face_index; long_t face_flags; long_t style_flags; - long_t num_glyphs; + long_t num_glyphs; //0x10 ptr_t family_name; //char* ptr_t style_name; //char* int num_fixed_sizes; - ptr_t available_sizes; //void* + ptr_t available_sizes; //FT_Bitmap_32_t* //0x20 int num_charmaps; ptr_t charmaps; //void* - FT_Generic_32_t generic; - FT_BBox_32_t bbox; - uint16_t units_per_EM; + FT_Generic_32_t generic; //0x28 + FT_BBox_32_t bbox; //0x30 + uint16_t units_per_EM; //0x40 int16_t ascender; int16_t descender; int16_t height; @@ -333,11 +351,11 @@ typedef struct FT_FaceRec_32_s int16_t max_advance_height; int16_t underline_position; int16_t underline_thickness; - ptr_t glyph; //FT_GlyphSlotRec_t* + ptr_t glyph; //FT_GlyphSlotRec_t* //0x50 ptr_t size; //void* ptr_t charmap; //void* /*@private begin */ - ptr_t driver; //void* + ptr_t driver; //void* //0x5c ptr_t memory; //void* ptr_t stream; //FT_StreamDesc_t* FT_ListRec_32_t sizes_list; @@ -485,6 +503,16 @@ void inplace_FT_FaceRec_shrink(void* a) dst->num_glyphs = to_long(src->num_glyphs); dst->family_name = to_ptrv(src->family_name); dst->style_name = to_ptrv(src->style_name); + { + FT_Bitmap_Size_32_t* dst_sizes = (void*)src->available_sizes; + for(int i=0; inum_fixed_sizes; ++i) { + dst_sizes[i].height = src->available_sizes[i].height; + dst_sizes[i].width = src->available_sizes[i].width; + dst_sizes[i].size = to_long(src->available_sizes[i].size); + dst_sizes[i].x_ppem = to_long(src->available_sizes[i].x_ppem); + dst_sizes[i].y_ppem = to_long(src->available_sizes[i].y_ppem); + } + } dst->num_fixed_sizes = src->num_fixed_sizes; dst->available_sizes = to_ptrv(src->available_sizes); dst->num_charmaps = src->num_charmaps; @@ -560,6 +588,16 @@ void inplace_FT_FaceRec_enlarge(void* a) dst->num_charmaps = src->num_charmaps; dst->available_sizes = from_ptrv(src->available_sizes); dst->num_fixed_sizes = src->num_fixed_sizes; + { + FT_Bitmap_Size_32_t* src_sizes = (void*)dst->available_sizes; + for(int i=dst->num_fixed_sizes-1; i>=0; --i) { + dst->available_sizes[i].height = src_sizes[i].height; + dst->available_sizes[i].width = src_sizes[i].width; + dst->available_sizes[i].size = from_long(src_sizes[i].size); + dst->available_sizes[i].x_ppem = from_long(src_sizes[i].x_ppem); + dst->available_sizes[i].y_ppem = from_long(src_sizes[i].y_ppem); + } + } dst->style_name = from_ptrv(src->style_name); dst->family_name = from_ptrv(src->family_name); dst->num_glyphs = from_long(src->num_glyphs); @@ -906,6 +944,16 @@ EXPORT int my32_FT_New_Face(x64emu_t* emu, void* lib, void* name, long index, pt return ret; } +EXPORT int my32_FT_New_Memory_Face(x64emu_t* emu, void* lib, void* base, long size, long index, ptr_t* face) +{ + FT_FaceRec_t* res = NULL; + int ret = my->FT_New_Memory_Face(lib, base, size, index, &res); + if(ret) return ret; + *face = to_ptrv(res); + inplace_FT_FaceRec_shrink(res); + return ret; +} + EXPORT int my32_FT_Done_Face(x64emu_t* emu, void* face) { inplace_FT_FaceRec_enlarge(face); @@ -920,6 +968,14 @@ EXPORT int my32_FT_Set_Char_Size(x64emu_t* emu, void* face, long char_width, lon return ret; } +EXPORT int my32_FT_Set_Pixel_Sizes(x64emu_t* emu, void* face, uint32_t width, uint32_t height) +{ + inplace_FT_FaceRec_enlarge(face); + int ret = my->FT_Set_Pixel_Sizes(face, width, height); + inplace_FT_FaceRec_shrink(face); + return ret; +} + EXPORT uint32_t my32_FT_Get_Char_Index(x64emu_t* emu, void* face, unsigned long code) { inplace_FT_FaceRec_enlarge(face); diff --git a/src/wrapped32/wrappedfreetype_private.h b/src/wrapped32/wrappedfreetype_private.h index 0a367df44..ee86daa8e 100644 --- a/src/wrapped32/wrappedfreetype_private.h +++ b/src/wrapped32/wrappedfreetype_private.h @@ -116,7 +116,7 @@ GOM(FT_Load_Glyph, iFEpui) //GO(FT_MulFix, lFll) GOM(FT_New_Face, iFEpplp) //GOM(FT_New_Library, iFEpp) -//GO(FT_New_Memory_Face, iFppllp) +GOM(FT_New_Memory_Face, iFEppllp) //GO(FT_New_Size, iFpp) //GOM(FT_Open_Face, iFEpplp) //GO(FT_OpenType_Free, vFpp) @@ -157,7 +157,7 @@ GOM(FT_Set_Char_Size, iFEplluu) //GO(FT_Set_Default_Properties, vFp) //GO(FT_Set_MM_Blend_Coordinates, //GO(FT_Set_MM_Design_Coordinates, iFpup) -//GO(FT_Set_Pixel_Sizes, iFpuu) +GOM(FT_Set_Pixel_Sizes, iFEpuu) //GO(FT_Set_Renderer, iFppup) //GO(FT_Set_Transform, vFppp) //GO(FT_Set_Var_Blend_Coordinates, diff --git a/src/wrapped32/wrappedlibc.c b/src/wrapped32/wrappedlibc.c index e19ff09e1..f4a0dff7d 100755 --- a/src/wrapped32/wrappedlibc.c +++ b/src/wrapped32/wrappedlibc.c @@ -37,6 +37,7 @@ #include #include #include +#include #include "wrappedlibs.h" @@ -3051,6 +3052,45 @@ EXPORT void* my32_malloc(unsigned long size) { return calloc(1, size); } + +struct sysinfo_32 { + long_t uptime; + ulong_t loads[3]; + ulong_t totalram; + ulong_t freeram; + ulong_t sharedram; + ulong_t bufferram; + ulong_t totalswap; + ulong_t freeswap; + uint16_t procs; + uint16_t pad; + ulong_t totalhigh; + ulong_t freehigh; + uint32_t mem_unit; + // removed padding +}; + +EXPORT int my32_sysinfo(struct sysinfo_32* p) +{ + struct sysinfo info = {0}; + int ret = sysinfo(&info); + p->uptime = from_long(info.uptime); + p->loads[0] = from_ulong(info.loads[0]); + p->loads[1] = from_ulong(info.loads[1]); + p->loads[2] = from_ulong(info.loads[2]); + p->totalram = from_ulong(info.totalram); + p->freeram = from_ulong(info.freeram); + p->sharedram = from_ulong(info.sharedram); + p->bufferram = from_ulong(info.bufferram); + p->totalswap = from_ulong(info.totalswap); + p->freeswap = from_ulong(info.freeswap); + p->procs = info.procs; + p->pad = info.pad; + p->totalhigh = from_ulong(info.totalhigh); + p->freehigh = from_ulong(info.freehigh); + p->mem_unit = info.mem_unit; + return ret; +} #if 0 #ifndef __NR_memfd_create #define MFD_CLOEXEC 0x0001U diff --git a/src/wrapped32/wrappedlibc_private.h b/src/wrapped32/wrappedlibc_private.h index c41355be0..1c6e5efbf 100755 --- a/src/wrapped32/wrappedlibc_private.h +++ b/src/wrapped32/wrappedlibc_private.h @@ -1773,7 +1773,7 @@ GO(__sysconf, lFi) //GO(__sysctl, iFp) //DATA(_sys_errlist, 4) //DATA(sys_errlist, 4) -//GO(sysinfo, iFp) +GOM(sysinfo, iFp) //%noE //GO2(syslog, vFipV, vsyslog) //GO2(__syslog_chk, vFiipV, __vsyslog_chk) //DATA(_sys_nerr, 4) // type R diff --git a/src/wrapped32/wrappedlibx11.c b/src/wrapped32/wrappedlibx11.c index 39648b8d5..7a36df967 100644 --- a/src/wrapped32/wrappedlibx11.c +++ b/src/wrapped32/wrappedlibx11.c @@ -2181,6 +2181,14 @@ EXPORT int my32_XNextEvent(x64emu_t* emu, void* dpy, my_XEvent_32_t* evt) return ret; } +EXPORT int my32_XPeekEvent(x64emu_t* emu, void* dpy, my_XEvent_32_t* evt) +{ + my_XEvent_t event = {0}; + int ret = my->XPeekEvent(dpy, &event); + convertXEvent(evt, &event); + return ret; +} + EXPORT int my32_XCheckTypedEvent(x64emu_t* emu, void* dpy, int type, my_XEvent_32_t* evt) { my_XEvent_t event = {0}; @@ -2196,6 +2204,20 @@ EXPORT int my32_XSendEvent(x64emu_t* emu, void* dpy, XID window, int propagate, return my->XSendEvent(dpy, window, propagate, mask, evt?(&event):NULL); } +EXPORT unsigned long my32_XLookupKeysym(x64emu_t* emu, my_XEvent_32_t* evt, int index) +{ + my_XEvent_t event = {0}; + if(evt) unconvertXEvent(&event, evt); + return my->XLookupKeysym(evt?(&event):NULL, index); +} + +EXPORT int my32_XLookupString(x64emu_t* emu, my_XEvent_32_t* evt, void* buff, int len, void* keysym, void* status) +{ + my_XEvent_t event = {0}; + if(evt) unconvertXEvent(&event, evt); + return my->XLookupString(evt?(&event):NULL, buff, len, keysym, status); +} + EXPORT int my32_XSetWMProtocols(x64emu_t* emu, void* dpy, XID window, XID_32* protocol, int count) { XID list[count]; diff --git a/src/wrapped32/wrappedlibx11_private.h b/src/wrapped32/wrappedlibx11_private.h index f12663d76..952eb3553 100644 --- a/src/wrapped32/wrappedlibx11_private.h +++ b/src/wrapped32/wrappedlibx11_private.h @@ -880,9 +880,9 @@ GO(XLockDisplay, vFX) DATAB(_XLockMutex_fn, 4) GO(XLookupColor, iFXLpBLWWWcc_BLWWWcc_) //GO(_XLookupKeysym, -//GO(XLookupKeysym, LFpi) +GOM(XLookupKeysym, LFEpi) //GO(_XLookupString, -//GO(XLookupString, iFppipp) +GOM(XLookupString, iFEppipp) GO(XLowerWindow, iFXL) GO(XMapRaised, iFXL) GO(XMapSubwindows, iFXL) @@ -942,7 +942,7 @@ GO(XOpenIM, pFXppp) //GO(_XParseBaseFontNameList, GO(XParseColor, iFXLpBLWWWcc_) //GO(XParseGeometry, iFppppp) -//GO(XPeekEvent, iFpp) +GOM(XPeekEvent, iFEXp) //GOM(XPeekIfEvent, iFEpppp) GO(XPending, iFX) //GO(Xpermalloc, pFu) diff --git a/src/wrapped32/wrappedlibxxf86vm_private.h b/src/wrapped32/wrappedlibxxf86vm_private.h index f7eb34199..cdb1814eb 100644 --- a/src/wrapped32/wrappedlibxxf86vm_private.h +++ b/src/wrapped32/wrappedlibxxf86vm_private.h @@ -6,21 +6,21 @@ //GO(XF86VidModeValidateModeLine, iFpip) //GO(XF86VidModeGetGamma, iFpip) //GO(XF86VidModeSetGamma, iFpip) -//GO(XF86VidModeSetClientVersion, iFp) -//GO(XF86VidModeGetGammaRamp, iFpiippp) +GO(XF86VidModeSetClientVersion, iFX) +GO(XF86VidModeGetGammaRamp, iFXiippp) //GO(XF86VidModeGetMonitor, iFpip) -//GO(XF86VidModeQueryVersion, iFppp) +GO(XF86VidModeQueryVersion, iFXpp) //GO(XF86VidModeDeleteModeLine, iFpip) //GO(XF86VidModeGetModeLine, iFpipp) //GO(XF86VidModeGetAllModeLines, iFpipp) -//GO(XF86VidModeSetGammaRamp, iFpiippp) +GO(XF86VidModeSetGammaRamp, iFXiippp) //GO(XF86VidModeGetPermissions, iFpip) //GO(XF86VidModeModModeLine, iFpip) //GO(XF86VidModeSetViewPort, iFpiii) -//GO(XF86VidModeSwitchMode, iFpii) +GO(XF86VidModeSwitchMode, iFXii) //GO(XF86VidModeAddModeLine, iFpipp) //GO(XF86VidModeSwitchToMode, iFpip) -//GO(XF86VidModeQueryExtension, iFppp) -//GO(XF86VidModeGetGammaRampSize, iFpip) +GO(XF86VidModeQueryExtension, iFXpp) +GO(XF86VidModeGetGammaRampSize, iFXip) //GO(XF86VidModeGetDotClocks, iFpipppp) -//GO(XF86VidModeLockModeSwitch, iFpii) +GO(XF86VidModeLockModeSwitch, iFXii)