goat3dgfx
view src/vr/vr_impl.h @ 13:25bf39105c82
lalal
author | John Tsiombikas <nuclear@member.fsf.org> |
---|---|
date | Wed, 27 Nov 2013 08:08:59 +0200 |
parents | |
children | 7d6b667821cf |
line source
1 #ifndef VR_IMPL_H_
2 #define VR_IMPL_H_
4 #include <OVR.h>
6 using namespace OVR;
8 struct VRContext {
9 DeviceManager *ovr_devman;
10 HMDDevice *ovr_hmd_dev;
11 SensorDevice *ovr_sensor_dev;
12 SensorFusion ovr_sfusion;
14 struct {
15 char *display;
16 int display_xoffs, display_yoffs;
18 // the full width and height of the display (both eyes)
19 int width, height;
20 float fov;
21 // the full aspect ratio of the display (both eyes)
22 float aspect;
23 float ipd;
24 float distort[4];
25 // the right lens center offset (negate for left)
26 float lens_center_offset;
27 float proj_center_offset;
28 float scale; // scaling to be applied to the two views to fill the screen
29 } info;
30 };
32 extern VRContext vr_ctx;
34 bool vr_gl_init();
36 #endif // VR_IMPL_H_