diff --git a/vrclient_x64/cppIVRTrackedCamera_IVRTrackedCamera_001.cpp b/vrclient_x64/cppIVRTrackedCamera_IVRTrackedCamera_001.cpp index 00a171d3..2e3ca742 100644 --- a/vrclient_x64/cppIVRTrackedCamera_IVRTrackedCamera_001.cpp +++ b/vrclient_x64/cppIVRTrackedCamera_IVRTrackedCamera_001.cpp @@ -81,14 +81,6 @@ NTSTATUS IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamElapsedTime( void * return 0; } -NTSTATUS IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame( void *args ) -{ - struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params *params = (struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params *)args; - struct u_IVRTrackedCamera_IVRTrackedCamera_001 *iface = (struct u_IVRTrackedCamera_IVRTrackedCamera_001 *)params->linux_side; - params->_ret = (const w_CameraVideoStreamFrame_t_0914 *)iface->GetVideoStreamFrame( params->nDeviceIndex ); - return 0; -} - NTSTATUS IVRTrackedCamera_IVRTrackedCamera_001_ReleaseVideoStreamFrame( void *args ) { struct IVRTrackedCamera_IVRTrackedCamera_001_ReleaseVideoStreamFrame_params *params = (struct IVRTrackedCamera_IVRTrackedCamera_001_ReleaseVideoStreamFrame_params *)args; diff --git a/vrclient_x64/gen_wrapper.py b/vrclient_x64/gen_wrapper.py index aa7484dc..964b1e5d 100755 --- a/vrclient_x64/gen_wrapper.py +++ b/vrclient_x64/gen_wrapper.py @@ -244,6 +244,7 @@ MANUAL_METHODS = { "IVRMailbox_undoc3": lambda ver, abi: abi == 'u', "IVROverlay_SetOverlayTexture": True, "IVRInput_GetDigitalActionData": lambda ver, abi: abi == 'w' and ver > 3, + "IVRTrackedCamera_GetVideoStreamFrame": True, } diff --git a/vrclient_x64/unixlib.cpp b/vrclient_x64/unixlib.cpp index 2081d5fe..c2271cb5 100644 --- a/vrclient_x64/unixlib.cpp +++ b/vrclient_x64/unixlib.cpp @@ -114,3 +114,11 @@ NTSTATUS vrclient_VRClientCoreFactory( void *args ) params->_ret = p_VRClientCoreFactory( params->name, params->return_code ); return 0; } + +NTSTATUS IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame( void *args ) +{ + struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params *params = (struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params *)args; + struct u_IVRTrackedCamera_IVRTrackedCamera_001 *iface = (struct u_IVRTrackedCamera_IVRTrackedCamera_001 *)params->linux_side; + *(w_CameraVideoStreamFrame_t_0914 *)params->_ret = *iface->GetVideoStreamFrame( params->nDeviceIndex ); + return 0; +} diff --git a/vrclient_x64/vrclient_main.c b/vrclient_x64/vrclient_main.c index 7d79b55e..e0222e4c 100644 --- a/vrclient_x64/vrclient_main.c +++ b/vrclient_x64/vrclient_main.c @@ -516,3 +516,17 @@ bool __thiscall winIVRClientCore_IVRClientCore_003_BIsHmdPresent( struct w_steam return TRUE; } + +const w_CameraVideoStreamFrame_t_0914 * __thiscall winIVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame(struct w_steam_iface *_this, uint32_t nDeviceIndex) +{ + static w_CameraVideoStreamFrame_t_0914 w_frame; + struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params params = + { + .linux_side = _this->u_iface, + .nDeviceIndex = nDeviceIndex, + ._ret = &w_frame, + }; + TRACE("%p\n", _this); + VRCLIENT_CALL( IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame, ¶ms ); + return params._ret; +} diff --git a/vrclient_x64/winIVRTrackedCamera.c b/vrclient_x64/winIVRTrackedCamera.c index a5d48b0a..6d31ef93 100644 --- a/vrclient_x64/winIVRTrackedCamera.c +++ b/vrclient_x64/winIVRTrackedCamera.c @@ -154,17 +154,7 @@ float __thiscall winIVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamElapsedT return params._ret; } -const w_CameraVideoStreamFrame_t_0914 * __thiscall winIVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame(struct w_steam_iface *_this, uint32_t nDeviceIndex) -{ - struct IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame_params params = - { - .linux_side = _this->u_iface, - .nDeviceIndex = nDeviceIndex, - }; - TRACE("%p\n", _this); - VRCLIENT_CALL( IVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame, ¶ms ); - return params._ret; -} +extern const w_CameraVideoStreamFrame_t_0914 * __thiscall winIVRTrackedCamera_IVRTrackedCamera_001_GetVideoStreamFrame(struct w_steam_iface *_this, uint32_t nDeviceIndex); bool __thiscall winIVRTrackedCamera_IVRTrackedCamera_001_ReleaseVideoStreamFrame(struct w_steam_iface *_this, uint32_t nDeviceIndex, const w_CameraVideoStreamFrame_t_0914 *pFrameImage) {