Commit Graph

189 Commits

Author SHA1 Message Date
Rémi Bernon
d8038254d4 lsteamclient: Simplify unix side parameter conversions.
CW-Bug-Id: #22729
2024-02-15 15:53:25 +02:00
Rémi Bernon
1e11264606 lsteamclient: Allocate memory for every path conversion.
CW-Bug-Id: #22729
2024-02-15 15:53:25 +02:00
Rémi Bernon
10d907c5f7 lsteamclient: Simplify path convertion using separate dicts.
CW-Bug-Id: #22729
2024-02-15 15:53:25 +02:00
Rémi Bernon
7e5eed6c71 lsteamclient: Use a generic interface wrapper struct.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
224f0af6ad lsteamclient: Use with statement to generate the .c files.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
42b0968c32 lsteamclient: Generate the .h and .cpp files separately.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
9130b93597 lsteamclient: Pass write function as parameter to handle_method*.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
7b11b2a3a6 lsteamclient: Replace do_cb_wrap with (alloc|convert)_callback.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
8d78cb5107 lsteamclient: Consistently use the computed return type.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
f6871a6b73 lsteamclient: Always use a return result variable.
CW-Bug-Id: #22729
2024-02-15 15:53:24 +02:00
Rémi Bernon
c34fc635ce lsteamclient: Cleanup C method generator.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
caa21ea5d0 lsteamclient: Generate thiscall wrappers separately.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
ad8cbcfc2d lsteamclient: Introduce a new Method cursor wrapper.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
e9e6dd3117 lsteamclient: Introduce a new Class cursor wrapper.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
4fc0934c83 lsteamclient: Use the names array for the param converters.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
122e0e362c lsteamclient: Use declspec to generate C++ method signature.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
e1c7f3e3f3 lsteamclient: Split C++/C method generation helpers.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
c9dda0d5b7 lsteamclient: Reorder do_cb_wrap first parameters.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
064d511e66 lsteamclient: Split cpp_h generation to a dedicated method.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
9bf3f81987 lsteamclient: Return all struct abis from find_struct.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
f31b6d43fb lsteamclient: Filter structs and classes while parsing.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
18e3344745 lsteamclient: Use the all_records dict to lookup structs.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
c3cb0a26b0 lsteamclient: Introduce new canonical_typename helper.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
9da0e96f94 lsteamclient: Sort classes by their version string.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
e4ca59abab lsteamclient: Filter classes by version before generating.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
cc1963dbba lsteamclient: Strip interface version suffixes early.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
f19380c190 lsteamclient: Parse SDK versions and ABIs in parallel.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
d4cb359f4b lsteamclient: Split loading, parsing, and generating steps.
CW-Bug-Id: #22729
2024-02-15 15:53:23 +02:00
Rémi Bernon
f6bb931d9a lsteamclient: Introduce a dedicated parsing function.
CW-Bug-Id: #22729
2024-02-15 15:53:22 +02:00
Rémi Bernon
ff2999e563 lsteamclient: Use a dict for SDK sources / class mapping.
CW-Bug-Id: #22729
2024-02-15 15:53:22 +02:00
Rémi Bernon
adbe64d4bf lsteamclient: Use upper-case global constants.
CW-Bug-Id: #22729
2024-02-15 15:53:22 +02:00
Rémi Bernon
5f6ee9a06e lsteamclient: Remove unused imports and duplicate entries.
CW-Bug-Id: #22729
2024-02-15 15:53:22 +02:00
Arkadiusz Hiler
c0d0b2f295 lsteamclient: Generate SteamWorks SDK 1.58 support. 2023-09-27 20:14:12 +03:00
Paul Gofman
516f76e446 lsteamclient: Terminate callback thread on Steam interface shutdown.
CW-Bug-Id: #22649
2023-09-12 14:44:08 +03:00
Rémi Bernon
ea07c02886 lsteamclient: Generate SteamWorks SDK 1.57 support. 2023-05-19 18:05:40 +03:00
Rémi Bernon
582047e3be lsteamclient: Generate SteamWorks SDK 1.56 support. 2023-05-19 18:05:27 +03:00
Rémi Bernon
49324a57d7 lsteamclient: Define __cdecl to nothing on the linux side. 2023-05-19 18:05:11 +03:00
Rémi Bernon
840959f4cf lsteamclient: Generate SteamWorks SDK 1.55 support. 2023-05-19 18:05:01 +03:00
Rémi Bernon
b661fabcbd lsteamclient: Generate SteamWorks SDK 1.54 support. 2023-05-19 18:04:49 +03:00
Paul Gofman
bcd3d5218f lsteamclient: Wrap SteamAPIWarningMessageHook_t callback.
CW-Bug-Id: #20813
2022-08-10 19:29:30 +03:00
Paul Gofman
ba3d473ec1 lsteamclient: Place vtables for some interfaces in native steamclient.dll data.
CW-Bug-Id: #20869
2022-08-03 14:24:42 +03:00
Arkadiusz Hiler
be4a80dac6 lsteamclient: Assume manual wrappers are needed for newer revisions of the interfaces. 2022-08-03 14:24:42 +03:00
Arkadiusz Hiler
db61ec1f1e lsteamclient: Wrap EnableActionEventCallbacks's callback also for SteamInput006. 2022-06-10 16:31:19 +03:00
Arkadiusz Hiler
05efcef3fa lsteamclient: Fixup paths for GetGlyph*() also in SteamInput006. 2022-06-10 16:31:17 +03:00
Arkadiusz Hiler
fd79f236ca lsteamclient: Bump clang to 13.0.1. 2022-06-10 16:31:15 +03:00
Paul Gofman
cd60b70756 lsteamclient: Fixup gameID parameter for SteamUser008_InitiateGameConnection().
CW-Bug-Id: #20195
2022-04-20 18:54:06 +03:00
Paul Gofman
e03828cdc3 lsteamclient: Also treat TypeKind.UNEXPOSED as unspecified function pointer in genwrapper.py. 2022-04-20 18:54:06 +03:00
Rémi Bernon
57ea5353ee lsteamclient: Parse all include files at once. 2022-01-19 11:29:54 +02:00
Rémi Bernon
226313fa1d lsteamclient: Remove unnecessary includes.
The -Isteamworks_sdk_{sdkver} was not expanded anyway.
2022-01-19 11:29:54 +02:00
Rémi Bernon
de5557448b lsteamclient: Use dicts to lookup structs in gen_wrapper.py. 2022-01-19 11:29:54 +02:00
Rémi Bernon
5e3dab64e2 lsteamclient: Import from clang.cindex instead of prefixing. 2022-01-19 11:29:54 +02:00
Andrew Eikum
212cbc0c9a lsteamclient: Generate steamworks sdk 1.53a support 2022-01-19 11:29:54 +02:00
Andrew Eikum
58860a6cc6 lsteamclient: Support reference parameters 2022-01-19 11:29:54 +02:00
Andrew Eikum
67316452df lsteamclient: Use python f-strings 2022-01-19 11:29:54 +02:00
Paul Gofman
7a90ff74ce lsteamclient: Get memory for SteamClient interface within native steamclient.dll loader range.
CW-Bug-ID: #19605

For Mafia II.
2021-11-11 18:36:07 +02:00
Andrew Eikum
0b1db713ac lsteamclient: Also convert paths from GetGlyphForXboxOrigin
CW-Bug-Id: #19517
2021-10-08 13:22:52 -05:00
Andrew Eikum
f9eef72c88 lsteamclient: Convert glyph paths in new ISteamInput005 methods
CW-Bug-Id: #19517
2021-10-08 13:22:52 -05:00
Andrew Eikum
4b9b102b31 lsteamclient: Convert path given to ISteamInput::SetInputActionManifestFilePath
CW-Bug-Id: #19517
2021-10-08 13:22:52 -05:00
Andrew Eikum
da911c3bf9 lsteamclient: generate 1.52 support 2021-10-08 13:22:51 -05:00
Andrew Eikum
5504754ce9 lsteamclient: generate 1.51 support 2021-03-31 14:08:10 -05:00
Giovanni Mascellani
e5c634ce0b Silence expected and harmless errors 2020-12-01 14:54:06 -06:00
Giovanni Mascellani
16992af05c Port gen_wrapper.py to Python 3
Basically the only issue left out is that Python3 is much more picky
on file encoding, and some Valve headers are not UTF-8. Ignoring
errors is enough to get everything fixed.
2020-12-01 14:54:06 -06:00
Giovanni Mascellani
04af5e3d79 Sort callback tables by id
This way the generated file is more deterministic, and hopefully less
irrelevant diff is produced (for example when switching from Python 2
to Python 3, or when adding more callbacks that cause rehashing the
dictionary).
2020-12-01 14:54:06 -06:00
Andrew Eikum
8bb3afc9a2 lsteamclient: Handle callbacks for ISteamNetworking interfaces 2020-10-02 14:22:48 -05:00
Andrew Eikum
30c21636c5 lsteamclient: support ISteamNetworkingMessages 2020-10-02 14:22:44 -05:00
Andrew Eikum
f22095c745 lsteamclient: generate 1.50 support 2020-10-02 14:22:39 -05:00
Andrew Eikum
c0aa7979a3 steamclient: Generate support for steamworks 1.49 2020-09-29 14:29:06 -05:00
Andrew Eikum
a853ce145d lsteamclient: Import steamworks 1.48a and fix up networkingsockets versions 2020-06-05 08:58:23 -05:00
Andrew Eikum
1bfc03a2c5 steamclient: generate 1.47 support 2020-01-10 07:49:46 -06:00
Andrew Eikum
03ed34405a steamclient: import steamworks 1.47 2020-01-10 07:49:45 -06:00
Andrew Eikum
63e14b5678 lsteamclient: Preserve command-line cdecl macro 2019-08-23 09:57:46 -05:00
Andrew Eikum
19ece0270b lsteamclient: Support ISteamRemotePlay 2019-08-23 09:57:46 -05:00
Andrew Eikum
19b53264bd lsteamclient: Generate 1.46 support 2019-08-23 09:57:46 -05:00
Andrew Eikum
35752dadb6 lsteamclient: Generate 1.45 support 2019-08-23 09:57:46 -05:00
Andrew Eikum
80465e2a7d lsteamclient: Fix SteamAPI_CheckCallbackRegistered_t calling convention 2019-08-23 09:57:46 -05:00
Andrew Eikum
22354ec32f lsteamclient: Restore some 64-bit struct layout conversions 2019-06-27 09:00:59 -05:00
Andrew Eikum
54bbd1093b lsteamclient: Convert file: URLs 2019-06-18 13:00:19 -05:00
Andrew Eikum
5b674f087a lsteamclient: Convert windows VK to xkeysym 2019-06-18 13:00:19 -05:00
Andrew Eikum
6540e58078 lsteamclient: Also check struct layouts in 64-bit 2019-06-18 13:00:19 -05:00
Andrew Eikum
381ab5f3dc lsteamclient: Explicitly specify alignment of sub-structs
SteamNetConnectionInfo_t has 8-byte alignment on win32, but 4-byte on
Linux. Since we use the same struct on each in lsteamclient,
winSteamNetConnectionStatusChangedCallback_t_712's members would
incorrectly be aligned to 4-byte boundaries.
2019-06-05 10:21:33 -05:00
Andrew Eikum
5ed5cbf286 lsteamclient: Fix SteamNetConnectionStatusChangedCallback_t conversion
It was declared inside an extern "C" block in the SDK, which for some
reason cindex doesn't include.
2019-06-05 10:21:32 -05:00
Andrew Eikum
6195cb8a0a lsteamclient: Add a manual override for the cpp side of the new networking API 2019-06-05 10:21:32 -05:00
Andrew Eikum
197f25db04 lsteamclient: wrap FSteamNetworkingSocketsDebugOutput 2019-05-17 15:10:50 -05:00
Andrew Eikum
aa4c6fcc22 lsteamclient: Add ISteamGameSearch support 2019-05-17 10:50:22 -05:00
Andrew Eikum
e94250ae57 lsteamclient: Add ISteamNetworkingUtils support 2019-05-17 10:50:20 -05:00
Andrew Eikum
649421bf26 lsteamclient: Add ISteamNetworkingSockets support 2019-05-17 10:50:16 -05:00
Andrew Eikum
528d5d26cf lsteamclient: Add steamworks sdk 1.44 support 2019-05-17 10:50:12 -05:00
Andrew Eikum
318a9df7a9 lsteamclient: Support ISteamInput 2019-03-07 07:45:44 -06:00
Andrew Eikum
f6c12f6333 lsteamclient: Support ISteamParties 2019-03-07 07:45:44 -06:00
Andrew Eikum
4880c3b3ab lsteamclient: Make Windows-side struct definitions available to C files 2019-03-07 07:45:44 -06:00
Andrew Eikum
2054bb97a9 lsteamclient: Import SDK version 1.43 2019-03-07 07:45:44 -06:00
Andrew Eikum
358e8a7c42 lsteamclient: Synthesize another unreleased SDK
For SteamNetworkingSocketsSerialized003.
2019-03-07 07:45:44 -06:00
Andrew Eikum
bdca0aa9c9 lsteamclient: Support SteamGameStats001 2019-02-18 14:28:07 -06:00
Duncan Ogilvie
01c0124bde Fix stdcall parameter size computation
Signed-off-by: Duncan Ogilvie <mr.exodia.tpodt@gmail.com>
2019-02-14 08:32:39 -06:00
Andrew Eikum
a14f231bd1 lsteamclient: Implement old version of ISteamMatchmakingServerListResponse 2019-02-14 08:32:39 -06:00
Andrew Eikum
10a04c2c4f lsteamclient: SteamApps001 is an alias for STEAMAPPS_INTERFACE_VERSION001 2019-02-14 08:32:39 -06:00
Andrew Eikum
0411076dce lsteamclient: Synthesize SDK version 0.99u
For SteamUser004.
2019-02-14 08:32:39 -06:00
Andrew Eikum
6957729897 lsteamclient: Synthesize SDK version 0.99v
For SteamUser005.
2019-02-14 08:32:39 -06:00
Andrew Eikum
9ddc3052b6 lsteamclient: Synthesize SDK version 0.99w
For SteamUser006.
2019-02-14 08:32:39 -06:00
Andrew Eikum
7c16226c51 lsteamclient: Synthesize an unreleased SDK
For SteamNetworkingSocketsSerialized002.
2019-02-14 08:32:39 -06:00