mirror of
https://github.com/ValveSoftware/Proton.git
synced 2025-01-14 15:48:11 +03:00
vrclient: Introduce VRCLIENT_HAVE_DXVK.
This commit is contained in:
parent
cad4edfed8
commit
c0f2627396
@ -16,8 +16,7 @@
|
|||||||
|
|
||||||
#include "initguid.h"
|
#include "initguid.h"
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
/* 32-bit Mac doesn't support Vulkan and thus DXVK */
|
|
||||||
#include "dxvk-interop.h"
|
#include "dxvk-interop.h"
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
@ -583,7 +582,7 @@ static EVRCompositorError ivrcompositor_submit_wined3d(
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
static EVRCompositorError ivrcompositor_submit_dxvk(
|
static EVRCompositorError ivrcompositor_submit_dxvk(
|
||||||
EVRCompositorError (*cpp_func)(void *, EVREye, Texture_t *, VRTextureBounds_t *, EVRSubmitFlags),
|
EVRCompositorError (*cpp_func)(void *, EVREye, Texture_t *, VRTextureBounds_t *, EVRSubmitFlags),
|
||||||
void *linux_side, EVREye eye, Texture_t *texture, VRTextureBounds_t *bounds, EVRSubmitFlags flags,
|
void *linux_side, EVREye eye, Texture_t *texture, VRTextureBounds_t *bounds, EVRSubmitFlags flags,
|
||||||
@ -753,7 +752,7 @@ EVRCompositorError ivrcompositor_submit(
|
|||||||
eye, texture, bounds, flags, version, user_data, wine_texture);
|
eye, texture, bounds, flags, version, user_data, wine_texture);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
{
|
{
|
||||||
IDXGIVkInteropSurface *dxvk_surface;
|
IDXGIVkInteropSurface *dxvk_surface;
|
||||||
|
|
||||||
@ -813,14 +812,14 @@ void ivrcompositor_post_present_handoff(void (*cpp_func)(void *),
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
if (user_data->dxvk_device)
|
if (user_data->dxvk_device)
|
||||||
user_data->dxvk_device->lpVtbl->LockSubmissionQueue(user_data->dxvk_device);
|
user_data->dxvk_device->lpVtbl->LockSubmissionQueue(user_data->dxvk_device);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
cpp_func(linux_side);
|
cpp_func(linux_side);
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
if (user_data->dxvk_device)
|
if (user_data->dxvk_device)
|
||||||
user_data->dxvk_device->lpVtbl->ReleaseSubmissionQueue(user_data->dxvk_device);
|
user_data->dxvk_device->lpVtbl->ReleaseSubmissionQueue(user_data->dxvk_device);
|
||||||
#endif
|
#endif
|
||||||
@ -869,14 +868,14 @@ EVRCompositorError ivrcompositor_wait_get_poses(
|
|||||||
|
|
||||||
TRACE("%p, %p, %u, %p, %u\n", linux_side, render_poses, render_pose_count, game_poses, game_pose_count);
|
TRACE("%p, %p, %u, %p, %u\n", linux_side, render_poses, render_pose_count, game_poses, game_pose_count);
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
if (user_data->dxvk_device)
|
if (user_data->dxvk_device)
|
||||||
user_data->dxvk_device->lpVtbl->LockSubmissionQueue(user_data->dxvk_device);
|
user_data->dxvk_device->lpVtbl->LockSubmissionQueue(user_data->dxvk_device);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
r = cpp_func(linux_side, render_poses, render_pose_count, game_poses, game_pose_count);
|
r = cpp_func(linux_side, render_poses, render_pose_count, game_poses, game_pose_count);
|
||||||
|
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
if (user_data->dxvk_device)
|
if (user_data->dxvk_device)
|
||||||
user_data->dxvk_device->lpVtbl->ReleaseSubmissionQueue(user_data->dxvk_device);
|
user_data->dxvk_device->lpVtbl->ReleaseSubmissionQueue(user_data->dxvk_device);
|
||||||
#endif
|
#endif
|
||||||
|
@ -1,5 +1,10 @@
|
|||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
|
/* 32-bit Mac doesn't support Vulkan and thus DXVK */
|
||||||
|
#if !defined(__APPLE__) || defined(__x86_64__)
|
||||||
|
#define VRCLIENT_HAVE_DXVK
|
||||||
|
#endif
|
||||||
|
|
||||||
/* TODO these should be generated */
|
/* TODO these should be generated */
|
||||||
typedef struct __winISteamClient winISteamClient;
|
typedef struct __winISteamClient winISteamClient;
|
||||||
typedef struct __winISteamUser winISteamUser;
|
typedef struct __winISteamUser winISteamUser;
|
||||||
@ -57,7 +62,7 @@ struct compositor_data
|
|||||||
{
|
{
|
||||||
ID3D11Device *d3d11_device;
|
ID3D11Device *d3d11_device;
|
||||||
IWineD3D11Device *wined3d_device;
|
IWineD3D11Device *wined3d_device;
|
||||||
#if !defined(__APPLE__) || defined(__x86_64__)
|
#ifdef VRCLIENT_HAVE_DXVK
|
||||||
IDXGIVkInteropDevice *dxvk_device;
|
IDXGIVkInteropDevice *dxvk_device;
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user