vrclient: Unwrap Submit vulkan objects on the unix side.

CW-Bug-Id: #22729
This commit is contained in:
Rémi Bernon 2023-11-16 22:18:59 +01:00 committed by Arkadiusz Hiler
parent 59205c21ee
commit 9219ad9490
20 changed files with 387 additions and 281 deletions

View file

@ -221,7 +221,7 @@ MANUAL_METHODS = {
"IVRClientCore_Cleanup": lambda ver, abi: abi == 'w',
"IVRSystem_GetDXGIOutputInfo": lambda ver, abi: abi == 'w',
"IVRSystem_GetOutputDevice": lambda ver, abi: abi == 'u' and ver > 16,
"IVRCompositor_Submit": lambda ver, abi: abi == 'w' and ver > 8,
"IVRCompositor_Submit": lambda ver, abi: ver > 8,
"IVRCompositor_SetSkyboxOverride": lambda ver, abi: ver > 8,
"IVRCompositor_PostPresentHandoff": lambda ver, abi: abi == 'w',
"IVRCompositor_WaitGetPoses": lambda ver, abi: abi == 'w' and ver > 15 and ver < 27,

View file

@ -33,14 +33,6 @@ NTSTATUS IVRCompositor_IVRCompositor_009_GetLastPoses( void *args )
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_009_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_009_Submit_params *params = (struct IVRCompositor_IVRCompositor_009_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_009 *iface = (struct u_IVRCompositor_IVRCompositor_009 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_009_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_009_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_009_ClearLastSubmittedFrame_params *)args;

View file

@ -33,14 +33,6 @@ NTSTATUS IVRCompositor_IVRCompositor_010_GetLastPoses( void *args )
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_010_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_010_Submit_params *params = (struct IVRCompositor_IVRCompositor_010_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_010 *iface = (struct u_IVRCompositor_IVRCompositor_010 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_010_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_010_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_010_ClearLastSubmittedFrame_params *)args;

View file

@ -33,14 +33,6 @@ NTSTATUS IVRCompositor_IVRCompositor_011_GetLastPoses( void *args )
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_011_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_011_Submit_params *params = (struct IVRCompositor_IVRCompositor_011_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_011 *iface = (struct u_IVRCompositor_IVRCompositor_011 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_011_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_011_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_011_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_012_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_012_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_012_Submit_params *params = (struct IVRCompositor_IVRCompositor_012_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_012 *iface = (struct u_IVRCompositor_IVRCompositor_012 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_012_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_012_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_012_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_013_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_013_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_013_Submit_params *params = (struct IVRCompositor_IVRCompositor_013_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_013 *iface = (struct u_IVRCompositor_IVRCompositor_013 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_013_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_013_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_013_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_014_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_014_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_014_Submit_params *params = (struct IVRCompositor_IVRCompositor_014_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_014 *iface = (struct u_IVRCompositor_IVRCompositor_014 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_014_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_014_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_014_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_015_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_015_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_015_Submit_params *params = (struct IVRCompositor_IVRCompositor_015_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_015 *iface = (struct u_IVRCompositor_IVRCompositor_015 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_015_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_015_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_015_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_016_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_016_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_016_Submit_params *params = (struct IVRCompositor_IVRCompositor_016_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_016 *iface = (struct u_IVRCompositor_IVRCompositor_016 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_016_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_016_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_016_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_017_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_017_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_017_Submit_params *params = (struct IVRCompositor_IVRCompositor_017_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_017 *iface = (struct u_IVRCompositor_IVRCompositor_017 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_017_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_017_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_017_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_018_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_018_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_018_Submit_params *params = (struct IVRCompositor_IVRCompositor_018_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_018 *iface = (struct u_IVRCompositor_IVRCompositor_018 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_018_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_018_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_018_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_019_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_019_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_019_Submit_params *params = (struct IVRCompositor_IVRCompositor_019_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_019 *iface = (struct u_IVRCompositor_IVRCompositor_019 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_019_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_019_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_019_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_020_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_020_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_020_Submit_params *params = (struct IVRCompositor_IVRCompositor_020_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_020 *iface = (struct u_IVRCompositor_IVRCompositor_020 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_020_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_020_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_020_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_021_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_021_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_021_Submit_params *params = (struct IVRCompositor_IVRCompositor_021_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_021 *iface = (struct u_IVRCompositor_IVRCompositor_021 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_021_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_021_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_021_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_022_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_022_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_022_Submit_params *params = (struct IVRCompositor_IVRCompositor_022_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_022 *iface = (struct u_IVRCompositor_IVRCompositor_022 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_022_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_022_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_022_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_024_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_024_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_024_Submit_params *params = (struct IVRCompositor_IVRCompositor_024_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_024 *iface = (struct u_IVRCompositor_IVRCompositor_024 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_024_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_024_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_024_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_026_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_026_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_026_Submit_params *params = (struct IVRCompositor_IVRCompositor_026_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_026 *iface = (struct u_IVRCompositor_IVRCompositor_026 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_026_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_026_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_026_ClearLastSubmittedFrame_params *)args;

View file

@ -41,14 +41,6 @@ NTSTATUS IVRCompositor_IVRCompositor_027_GetLastPoseForTrackedDeviceIndex( void
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_027_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_027_Submit_params *params = (struct IVRCompositor_IVRCompositor_027_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_027 *iface = (struct u_IVRCompositor_IVRCompositor_027 *)params->linux_side;
params->_ret = (uint32_t)iface->Submit( params->eEye, params->pTexture, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_027_ClearLastSubmittedFrame( void *args )
{
struct IVRCompositor_IVRCompositor_027_ClearLastSubmittedFrame_params *params = (struct IVRCompositor_IVRCompositor_027_ClearLastSubmittedFrame_params *)args;

View file

@ -13,16 +13,98 @@ static u_VRVulkanTextureData_t *unwrap_texture_vkdata( const w_VRVulkanTextureDa
return u_vkdata;
}
static u_VRVulkanTextureArrayData_t *unwrap_texture_vkdata_array( const w_VRVulkanTextureArrayData_t *w_vkdata, u_VRVulkanTextureArrayData_t *u_vkdata )
{
if (!w_vkdata) return NULL;
*u_vkdata = *w_vkdata;
u_vkdata->m_pDevice = p_get_native_VkDevice( w_vkdata->m_pDevice );
u_vkdata->m_pPhysicalDevice = p_get_native_VkPhysicalDevice( w_vkdata->m_pPhysicalDevice );
u_vkdata->m_pInstance = p_get_native_VkInstance( w_vkdata->m_pInstance );
u_vkdata->m_pQueue = p_get_native_VkQueue( w_vkdata->m_pQueue );
return u_vkdata;
}
static u_VRTextureWithPoseAndDepth_t unwrap_texture_with_pose_and_depth( const w_VRTextureWithPoseAndDepth_t *w_texture, uint32_t flags, u_VRVulkanTextureArrayData_t *u_vkdata,
u_VRVulkanTextureData_t *u_depth_vkdata )
{
u_VRTextureWithPoseAndDepth_t u_texture = *w_texture;
if (w_texture->eType == TextureType_Vulkan)
{
if (flags & Submit_VulkanTextureWithArrayData) u_texture.handle = unwrap_texture_vkdata_array( (w_VRVulkanTextureArrayData_t *)w_texture->handle, u_vkdata );
else u_texture.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->handle, (u_VRVulkanTextureData_t *)u_vkdata );
u_texture.depth.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->depth.handle, u_depth_vkdata );
}
return u_texture;
}
static u_VRTextureWithDepth_t unwrap_texture_with_depth( const w_VRTextureWithDepth_t *w_texture, uint32_t flags, u_VRVulkanTextureArrayData_t *u_vkdata,
u_VRVulkanTextureData_t *u_depth_vkdata )
{
u_VRTextureWithDepth_t u_texture = *w_texture;
if (w_texture->eType == TextureType_Vulkan)
{
if (flags & Submit_VulkanTextureWithArrayData) u_texture.handle = unwrap_texture_vkdata_array( (w_VRVulkanTextureArrayData_t *)w_texture->handle, u_vkdata );
else u_texture.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->handle, (u_VRVulkanTextureData_t *)u_vkdata );
/* We should maybe unwrap the vkdata but No Man Sky uses a garbage handle in its w_VRTextureDepthInfo_t, is this really used? */
u_texture.depth.handle = w_texture->depth.handle;
}
return u_texture;
}
static u_VRTextureWithPose_t unwrap_texture_with_pose( const w_VRTextureWithPose_t *w_texture, uint32_t flags, u_VRVulkanTextureArrayData_t *u_vkdata )
{
u_VRTextureWithPose_t u_texture = *w_texture;
if (w_texture->eType == TextureType_Vulkan)
{
if (flags & Submit_VulkanTextureWithArrayData) u_texture.handle = unwrap_texture_vkdata_array( (w_VRVulkanTextureArrayData_t *)w_texture->handle, u_vkdata );
else u_texture.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->handle, (u_VRVulkanTextureData_t *)u_vkdata );
}
return u_texture;
}
static u_Texture_t unwrap_texture_data( const w_Texture_t *w_texture, uint32_t flags, u_VRVulkanTextureArrayData_t *u_vkdata )
{
u_Texture_t u_texture = *w_texture;
if (w_texture->eType == TextureType_Vulkan)
u_texture.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->handle, (u_VRVulkanTextureData_t *)u_vkdata );
{
if (flags & Submit_VulkanTextureWithArrayData) u_texture.handle = unwrap_texture_vkdata_array( (w_VRVulkanTextureArrayData_t *)w_texture->handle, u_vkdata );
else u_texture.handle = unwrap_texture_vkdata( (w_VRVulkanTextureData_t *)w_texture->handle, (u_VRVulkanTextureData_t *)u_vkdata );
}
return u_texture;
}
static u_Texture_t *unwrap_submit_texture_data( const w_VRTextureWithPoseAndDepth_t *w_texture, uint32_t flags, u_VRTextureWithPoseAndDepth_t *u_texture,
u_VRVulkanTextureArrayData_t *u_vkdata, u_VRVulkanTextureData_t *u_depth_vkdata )
{
switch (flags & (Submit_TextureWithPose | Submit_TextureWithDepth))
{
default:
*(u_Texture_t *)u_texture = unwrap_texture_data( (const w_Texture_t *)w_texture, flags, u_vkdata );
break;
case Submit_TextureWithPose:
*(u_VRTextureWithPose_t *)u_texture = unwrap_texture_with_pose( (const w_VRTextureWithPose_t *)w_texture, flags, u_vkdata );
break;
case Submit_TextureWithDepth:
*(u_VRTextureWithDepth_t *)u_texture = unwrap_texture_with_depth( (const w_VRTextureWithDepth_t *)w_texture, flags, u_vkdata, u_depth_vkdata );
break;
case Submit_TextureWithPose | Submit_TextureWithDepth:
*u_texture = unwrap_texture_with_pose_and_depth( w_texture, flags, u_vkdata, u_depth_vkdata );
break;
}
return (u_Texture_t *)u_texture;
}
NTSTATUS IVRCompositor_IVRCompositor_019_GetVulkanDeviceExtensionsRequired( void *args )
{
struct IVRCompositor_IVRCompositor_019_GetVulkanDeviceExtensionsRequired_params *params = (struct IVRCompositor_IVRCompositor_019_GetVulkanDeviceExtensionsRequired_params *)args;
@ -306,3 +388,224 @@ NTSTATUS IVRCompositor_IVRCompositor_027_SetSkyboxOverride( void *args )
params->_ret = (uint32_t)iface->SetSkyboxOverride( textures, params->unTextureCount );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_009_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_009_Submit_params *params = (struct IVRCompositor_IVRCompositor_009_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_009 *iface = (struct u_IVRCompositor_IVRCompositor_009 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_010_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_010_Submit_params *params = (struct IVRCompositor_IVRCompositor_010_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_010 *iface = (struct u_IVRCompositor_IVRCompositor_010 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_011_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_011_Submit_params *params = (struct IVRCompositor_IVRCompositor_011_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_011 *iface = (struct u_IVRCompositor_IVRCompositor_011 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_012_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_012_Submit_params *params = (struct IVRCompositor_IVRCompositor_012_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_012 *iface = (struct u_IVRCompositor_IVRCompositor_012 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_013_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_013_Submit_params *params = (struct IVRCompositor_IVRCompositor_013_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_013 *iface = (struct u_IVRCompositor_IVRCompositor_013 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_014_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_014_Submit_params *params = (struct IVRCompositor_IVRCompositor_014_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_014 *iface = (struct u_IVRCompositor_IVRCompositor_014 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_015_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_015_Submit_params *params = (struct IVRCompositor_IVRCompositor_015_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_015 *iface = (struct u_IVRCompositor_IVRCompositor_015 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_016_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_016_Submit_params *params = (struct IVRCompositor_IVRCompositor_016_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_016 *iface = (struct u_IVRCompositor_IVRCompositor_016 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_017_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_017_Submit_params *params = (struct IVRCompositor_IVRCompositor_017_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_017 *iface = (struct u_IVRCompositor_IVRCompositor_017 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_018_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_018_Submit_params *params = (struct IVRCompositor_IVRCompositor_018_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_018 *iface = (struct u_IVRCompositor_IVRCompositor_018 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_019_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_019_Submit_params *params = (struct IVRCompositor_IVRCompositor_019_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_019 *iface = (struct u_IVRCompositor_IVRCompositor_019 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_020_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_020_Submit_params *params = (struct IVRCompositor_IVRCompositor_020_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_020 *iface = (struct u_IVRCompositor_IVRCompositor_020 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_021_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_021_Submit_params *params = (struct IVRCompositor_IVRCompositor_021_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_021 *iface = (struct u_IVRCompositor_IVRCompositor_021 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_022_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_022_Submit_params *params = (struct IVRCompositor_IVRCompositor_022_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_022 *iface = (struct u_IVRCompositor_IVRCompositor_022 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_024_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_024_Submit_params *params = (struct IVRCompositor_IVRCompositor_024_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_024 *iface = (struct u_IVRCompositor_IVRCompositor_024 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_026_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_026_Submit_params *params = (struct IVRCompositor_IVRCompositor_026_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_026 *iface = (struct u_IVRCompositor_IVRCompositor_026 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}
NTSTATUS IVRCompositor_IVRCompositor_027_Submit( void *args )
{
struct IVRCompositor_IVRCompositor_027_Submit_params *params = (struct IVRCompositor_IVRCompositor_027_Submit_params *)args;
struct u_IVRCompositor_IVRCompositor_027 *iface = (struct u_IVRCompositor_IVRCompositor_027 *)params->linux_side;
u_VRTextureWithPoseAndDepth_t u_texture;
u_VRVulkanTextureData_t u_depth_vkdata;
u_VRVulkanTextureArrayData_t u_vkdata;
u_Texture_t *submit = unwrap_submit_texture_data( (const w_VRTextureWithPoseAndDepth_t *)params->pTexture, params->nSubmitFlags,
&u_texture, &u_vkdata, &u_depth_vkdata );
params->_ret = (uint32_t)iface->Submit( params->eEye, submit, params->pBounds, params->nSubmitFlags );
return 0;
}

View file

@ -13,29 +13,16 @@ WINE_DEFAULT_DEBUG_CHANNEL(vrclient);
struct submit_state
{
void *submit;
w_Texture_t texture;
w_VRVulkanTextureArrayData_t vkdata;
union
{
struct
{
w_VRVulkanTextureData_t depth_vkdata;
w_VRTextureWithPoseAndDepth_t both;
w_VRTextureWithDepth_t depth;
w_VRTextureWithPose_t pose;
};
struct
{
VkImageLayout image_layout;
VkImageSubresourceRange subresources;
IDXGIVkInteropSurface *dxvk_surface;
IDXGIVkInteropDevice *dxvk_device;
};
};
VkImageLayout image_layout;
VkImageSubresourceRange subresources;
IDXGIVkInteropSurface *dxvk_surface;
IDXGIVkInteropDevice *dxvk_device;
};
static void load_compositor_texture_dxvk( uint32_t eye, const w_Texture_t *texture, uint32_t *flags, struct submit_state *state )
static const w_Texture_t *load_compositor_texture_dxvk( uint32_t eye, const w_Texture_t *texture, uint32_t *flags,
struct submit_state *state )
{
static const uint32_t supported_flags = Submit_LensDistortionAlreadyApplied | Submit_FrameDiscontinuty;
w_VRVulkanTextureData_t vkdata;
@ -47,23 +34,23 @@ static void load_compositor_texture_dxvk( uint32_t eye, const w_Texture_t *textu
if (!(texture_iface = texture->handle))
{
WARN( "No D3D11 texture %p.\n", texture );
return;
return texture;
}
if (FAILED(texture_iface->lpVtbl->QueryInterface( texture_iface, &IID_IDXGIVkInteropSurface,
(void **)&state->dxvk_surface )))
{
WARN( "Invalid D3D11 texture %p.\n", texture );
return;
return texture;
}
state->texture = vrclient_translate_texture_dxvk( texture, &vkdata, state->dxvk_surface, &state->dxvk_device,
&state->image_layout, &image_info );
state->vkdata.m_nImage = vkdata.m_nImage;
state->vkdata.m_pDevice = get_native_VkDevice( vkdata.m_pDevice );
state->vkdata.m_pPhysicalDevice = get_native_VkPhysicalDevice( vkdata.m_pPhysicalDevice );
state->vkdata.m_pInstance = get_native_VkInstance( vkdata.m_pInstance );
state->vkdata.m_pQueue = get_native_VkQueue( vkdata.m_pQueue );
state->vkdata.m_pDevice = vkdata.m_pDevice;
state->vkdata.m_pPhysicalDevice = vkdata.m_pPhysicalDevice;
state->vkdata.m_pInstance = vkdata.m_pInstance;
state->vkdata.m_pQueue = vkdata.m_pQueue;
state->vkdata.m_nQueueFamilyIndex = vkdata.m_nQueueFamilyIndex;
state->vkdata.m_nWidth = vkdata.m_nWidth;
state->vkdata.m_nHeight = vkdata.m_nHeight;
@ -92,6 +79,8 @@ static void load_compositor_texture_dxvk( uint32_t eye, const w_Texture_t *textu
state->image_layout, VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL );
state->dxvk_device->lpVtbl->FlushRenderingCommands( state->dxvk_device );
state->dxvk_device->lpVtbl->LockSubmissionQueue( state->dxvk_device );
return &state->texture;
}
static void free_compositor_texture_dxvk( struct submit_state *state )
@ -105,56 +94,6 @@ static void free_compositor_texture_dxvk( struct submit_state *state )
state->dxvk_surface->lpVtbl->Release( state->dxvk_surface );
}
static void load_compositor_texture_vulkan( uint32_t eye, const w_Texture_t *texture, uint32_t flags, struct submit_state *state )
{
w_VRVulkanTextureData_t *their_vkdata;
their_vkdata = texture->handle;
memcpy( &state->vkdata, their_vkdata, flags & Submit_VulkanTextureWithArrayData ? sizeof(w_VRVulkanTextureArrayData_t)
: sizeof(w_VRVulkanTextureData_t) );
state->vkdata.m_pDevice = get_native_VkDevice( state->vkdata.m_pDevice );
state->vkdata.m_pPhysicalDevice = get_native_VkPhysicalDevice( state->vkdata.m_pPhysicalDevice );
state->vkdata.m_pInstance = get_native_VkInstance( state->vkdata.m_pInstance );
state->vkdata.m_pQueue = get_native_VkQueue( state->vkdata.m_pQueue );
switch (flags & (Submit_TextureWithPose | Submit_TextureWithDepth))
{
case 0:
state->texture = *texture;
state->texture.handle = &state->vkdata;
break;
case Submit_TextureWithPose:
state->pose = *(w_VRTextureWithPose_t *)texture;
state->pose.handle = &state->vkdata;
state->submit = &state->pose;
break;
case Submit_TextureWithDepth:
state->depth = *(w_VRTextureWithDepth_t *)texture;
state->depth.handle = &state->vkdata;
state->submit = &state->depth;
break;
case Submit_TextureWithPose | Submit_TextureWithDepth:
state->both = *(w_VRTextureWithPoseAndDepth_t *)texture;
state->both.handle = &state->vkdata;
their_vkdata = state->both.depth.handle;
state->depth_vkdata = *their_vkdata;
state->depth_vkdata.m_pDevice = get_native_VkDevice( state->depth_vkdata.m_pDevice );
state->depth_vkdata.m_pPhysicalDevice = get_native_VkPhysicalDevice( state->depth_vkdata.m_pPhysicalDevice );
state->depth_vkdata.m_pInstance = get_native_VkInstance( state->depth_vkdata.m_pInstance );
state->depth_vkdata.m_pQueue = get_native_VkQueue( state->depth_vkdata.m_pQueue );
state->both.depth.handle = &state->depth_vkdata;
state->submit = &state->both;
break;
}
}
struct set_skybox_override_state
{
w_Texture_t textures[6];
@ -277,20 +216,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_009_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_009_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_009_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -325,20 +264,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_010_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_010_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_010_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -373,20 +312,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_011_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_011_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_011_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -421,20 +360,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_012_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_012_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_012_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -469,20 +408,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_013_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_013_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_013_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -517,20 +456,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_014_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_014_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_014_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -565,20 +504,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_015_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_015_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_015_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -632,20 +571,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_016_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_016_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_016_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -699,20 +638,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_017_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_017_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_017_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -766,20 +705,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_018_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_018_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_018_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -833,20 +772,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_019_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_019_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_019_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -900,20 +839,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_020_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_020_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_020_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -983,20 +922,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_021_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_021_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_021_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -1082,20 +1021,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_022_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_022_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_022_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -1181,20 +1120,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_024_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_024_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_024_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -1280,20 +1219,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_026_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_026_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_026_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;
@ -1344,20 +1283,20 @@ uint32_t __thiscall winIVRCompositor_IVRCompositor_027_Submit( struct w_steam_if
uint32_t eEye, const w_Texture_t *pTexture,
const VRTextureBounds_t *pBounds, uint32_t nSubmitFlags )
{
struct submit_state state = {.texture = *pTexture, .submit = &state.texture};
struct submit_state state = {0};
struct IVRCompositor_IVRCompositor_027_Submit_params params =
{
.linux_side = _this->u_iface,
.eEye = eEye,
.pTexture = pTexture,
.pBounds = pBounds,
.nSubmitFlags = nSubmitFlags,
};
TRACE( "%p\n", _this );
compositor_data.handoff_called = FALSE;
if (pTexture->eType == TextureType_DirectX) load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
if (pTexture->eType == TextureType_Vulkan) load_compositor_texture_vulkan( eEye, pTexture, nSubmitFlags, &state );
params.pTexture = state.submit;
if (pTexture->eType == TextureType_DirectX)
params.pTexture = load_compositor_texture_dxvk( eEye, pTexture, &params.nSubmitFlags, &state );
VRCLIENT_CALL( IVRCompositor_IVRCompositor_027_Submit, &params );
if (pTexture->eType == TextureType_DirectX) free_compositor_texture_dxvk( &state );
return params._ret;