blob: 5fe521e7928b6283e81b96cc2b042c8ed311927c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
#ifndef TYPEDEFS_HEADER_FILE
#define TYPEDEFS_HEADER_FILE
#include <wiimote.h>
typedef struct FrustumParms
{
double m_dHeadTrackLedDist; //distance between leds on head in millimeters
double m_dRadPerCameraPixel; //radians per camera pixel
double m_dCameraXCenter; //the coordinates of the center of the camera
double m_dCameraYCenter; //
double m_dYAngleCorrection; //the correction added to the verticle angle measured by the camera (in radians)
double m_dCameraYOffset; //the offset in Y direction of the camera relative to the center of the screen (in mm)
double m_dScreenHeightMM; //the height of the screen (in mm)
double m_dScreenAspect; //the aspect ratio of the screen (width/height)
double m_dScreenHeightWorld; //the height of the screen (in world coordinates)
double m_dEyeDistMM; //distance between the eyes (in mm)
double m_dDefHeadDistMM; //default distance between head and display (in mm)
} FrustumParms_t;
typedef enum EyeOrigin {
STEREO_LEFT_EYE = 0,
STEREO_RIGHT_EYE = 1,
MONO_CENTER = 2
} EyeOrigin_t;
typedef struct GameState
{
FrustumParms_t m_FrustumParms;
bool m_bHeadTrackingEnabled;
bool m_bStereoEnabled;
wiimote *m_pTrackingWiimote;
GLuint m_GreyScaleShaderProgram; //handle to the grayscale shader program
GLint m_GSConvScaleLoc; //handle to the g_ConversionScale variable in the shader
GLfloat m_GSConvScale[3]; //grayscale conversion scale (default 0.299, 0.587, 0.114)
} GameState_t;
#endif //TYPEDEFS_HEADER_FILE
|