nuclear@4: #ifndef VR_H_ nuclear@4: #define VR_H_ nuclear@4: nuclear@4: #ifdef __cplusplus nuclear@4: extern "C" { nuclear@4: #endif nuclear@4: nuclear@4: int vr_init(void); nuclear@4: void vr_shutdown(void); nuclear@4: nuclear@4: int vr_module_count(void); nuclear@4: const char *vr_module_name(int idx); nuclear@4: nuclear@4: int vr_use_module(int idx); nuclear@4: int vr_use_module_named(const char *name); nuclear@4: nuclear@4: /* returns non-zero if the active vr module provides this kind of matrix nuclear@4: * information, otherwise it returns zero, and sets mat to identity nuclear@4: */ nuclear@4: int vr_view_matrix(int eye, float *mat); nuclear@4: int vr_proj_matrix(int eye, float *mat); nuclear@4: nuclear@4: /* fbtex should be a texture containing both eye views side by side (LR) */ nuclear@4: void vr_present(unsigned int fbtex); nuclear@4: nuclear@4: /* set the area of the framebuffer texture to be used */ nuclear@4: void vr_fbrect(float u, float umax, float v, float vmax); nuclear@4: nuclear@4: #ifdef __cplusplus nuclear@4: } nuclear@4: #endif nuclear@4: nuclear@4: #endif /* VR_H_ */