From 9943ae3f1a4fa1b687c780419b7f3a2d8091abe0 Mon Sep 17 00:00:00 2001 From: Dalai Felinto Date: Mon, 14 Dec 2015 19:01:32 -0200 Subject: New 3D Mode: Pageflip The pageflip mode requires a stereo quadbuffer, and a modern graphic card. Patch tested with NVidia 3D Vision. The mini-map is not drawn, but that's what is done for topbottom and sidebyside modes as well. Also most of the time the user would prefer the HUD to be off. That's for the user to decide though, and toggle it manually. Finally, the interocular distance (aka eye separation) is twice as much as the "3d_paralax_strength" settings. I find this a strange design decision. I didn't want to chance this though, since it's how the other 3d modes interpret this settings. --- src/client/clientlauncher.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/client') diff --git a/src/client/clientlauncher.cpp b/src/client/clientlauncher.cpp index dfddef34e..be6426627 100644 --- a/src/client/clientlauncher.cpp +++ b/src/client/clientlauncher.cpp @@ -512,6 +512,9 @@ bool ClientLauncher::create_engine_device() u16 bits = g_settings->getU16("fullscreen_bpp"); u16 fsaa = g_settings->getU16("fsaa"); + // stereo buffer required for pageflip stereo + bool stereo_buffer = g_settings->get("3d_mode") == "pageflip"; + // Determine driver video::E_DRIVER_TYPE driverType = video::EDT_OPENGL; std::string driverstring = g_settings->get("video_driver"); @@ -537,6 +540,7 @@ bool ClientLauncher::create_engine_device() params.AntiAlias = fsaa; params.Fullscreen = fullscreen; params.Stencilbuffer = false; + params.Stereobuffer = stereo_buffer; params.Vsync = vsync; params.EventReceiver = receiver; params.HighPrecisionFPU = g_settings->getBool("high_precision_fpu"); -- cgit v1.2.3