cmake build support for VR demo (WIN32 only)
update to latest OpenVR 1.05 SDK from https://github.com/ValveSoftware/openvr add keyboard support to tune default camera VR position VR revert to double 'distorted' views on Desktop, since the single view isn't showing full scene
This commit is contained in:
27
examples/ThirdPartyLibs/openvr/samples/shared/compat.h
Normal file
27
examples/ThirdPartyLibs/openvr/samples/shared/compat.h
Normal file
@@ -0,0 +1,27 @@
|
||||
#ifndef OPENVR_SAMPLES_SHARED_COMPAT_H_
|
||||
#define OPENVR_SAMPLES_SHARED_COMPAT_H_
|
||||
|
||||
#include <cstdio>
|
||||
#include <cstring>
|
||||
#include <cassert>
|
||||
|
||||
// Handle non standard code.
|
||||
#ifndef _WIN32
|
||||
|
||||
#include <cstdbool>
|
||||
#include <unistd.h>
|
||||
|
||||
#define sprintf_s snprintf
|
||||
#define vsprintf_s sprintf
|
||||
#define _stricmp strcmp
|
||||
#define stricmp strcmp
|
||||
#define strcpy_s(dst, n, src) int(strncpy(dst, src, n) != nullptr)
|
||||
#define fopen_s(fd, path, mode) int((*fd = fopen(path, mode)) != nullptr)
|
||||
#define _vsnprintf_s(buffer, size, fmt, ap) vsnprintf(buffer, size, fmt, ap)
|
||||
#define OutputDebugStringA(x) fprintf(stderr, "%s\n", x)
|
||||
|
||||
typedef int errno_t;
|
||||
|
||||
#endif // _WIN32
|
||||
|
||||
#endif // OPENVR_SAMPLES_SHARED_COMPAT_H_
|
||||
Reference in New Issue
Block a user