int all_white = 0;
#ifdef HAVE_OVR
int eye;
+ int vr = 1;
+#else
+ int vr = 0;
#endif
last_time = ticks_sdl();
{
#endif
/* clear screen */
-#ifdef HAVE_OVR
- opengl_clear(1);
-#else
- opengl_clear(0);
-#endif
+ opengl_clear(vr);
/* render benson + osd ontop of improved opengl rendering, if enabled */
if (render_improved) {
#ifndef HAVE_OVR
/* render improved graphics, interpolate, if required,
* if no item list is available, for legacy rendering
*/
-#ifdef HAVE_OVR
if (all_white)
- rc = render_all_white(1);
+ rc = render_all_white(vr);
else
- rc = render_all_items((config_amiga_speed) ? 1.0 : frame_time, 1);
-#else
- if (all_white)
- rc = render_all_white(0);
- else
- rc = render_all_items((config_amiga_speed) ? 1.0 : frame_time, 0);
-#endif
+ rc = render_all_items((config_amiga_speed) ? 1.0 : frame_time, vr);
if (rc)
goto goto_legacy;
-#ifdef HAVE_OVR
- opengl_blit_image(image, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, 1, config_fov, config_monitor_distance, benson_size, 1);
-#else
- opengl_blit_image(image, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, 1, config_fov, config_monitor_distance, benson_size, 0);
-#endif
+ opengl_blit_image(image, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, 1, config_fov, config_monitor_distance, benson_size, vr);
if (help_view)
-#ifdef HAVE_OVR
- opengl_blit_osd(0, help_osd[help_view - 1], config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, FOV_NOVAGEN, config_monitor_distance, 1.0, 1.0, 1.0, 0.0, 0.0);
-#else
- opengl_blit_osd(0, help_osd[help_view - 1], config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, config_fov, config_monitor_distance, benson_size, 1.0, 1.0, 0.0, 0.0);
-#endif
+ opengl_blit_osd(0, help_osd[help_view - 1], config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, (vr) ? FOV_NOVAGEN : config_fov, config_monitor_distance, (vr) ? 1.0 : benson_size, 1.0, 1.0, 0.0, 0.0);
if (osd_timer) {
-#ifdef HAVE_OVR
- opengl_blit_osd(1, info_osd, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, FOV_NOVAGEN, config_monitor_distance, 1.0, 0.5, 0.04, 0.5, -0.95);
-#else
- opengl_blit_osd(1, info_osd, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, config_fov, config_monitor_distance, benson_size, 0.5, 0.04, 0.5, -0.95);
-#endif
+ opengl_blit_osd(1, info_osd, config_video_filter, (double_pixel_size) ? BENSON_AT_LINE * 2 : BENSON_AT_LINE, (vr) ? FOV_NOVAGEN : config_fov, config_monitor_distance, (vr) ? 1.0 : benson_size, 0.5, 0.04, 0.5, -0.95);
if (osd_timer - (int32_t)ticks_sdl() < 0)
osd_timer = 0;
}
/* init SDL and OpenGL */
#ifdef HAVE_OVR
int vbl_sync = 0;
- int rift = 1;
+ int vr = 1;
int multisampling = 0;
window_width = SCREEN_WIDTH;
window_height = SCREEN_HEIGHT;
#else
int vbl_sync = 1;
- int rift = 0;
+ int vr = 0;
int multisampling = config_multisampling;
window_width = (config_debug_opengl) ? SCREEN_WIDTH / 3 * 2 : SCREEN_WIDTH;
window_height = (config_debug_opengl) ? SCREEN_HEIGHT / 3 * 4 : SCREEN_HEIGHT;
#endif
- rc = init_sdl(argv[0], window_width, window_height, SOUND_SAMPLERATE, sdl_sound_chunk, keyboard_sdl, audio_sdl, resize_window, multisampling, vbl_sync, rift);
+ rc = init_sdl(argv[0], window_width, window_height, SOUND_SAMPLERATE, sdl_sound_chunk, keyboard_sdl, audio_sdl, resize_window, multisampling, vbl_sync, vr);
if (rc < 0)
goto done;
#ifdef HAVE_OVR