]> git.tdb.fi Git - libs/vr.git/commitdiff
Set zero swap interval in the OpenVR combiner
authorMikko Rasa <tdb@tdb.fi>
Mon, 3 Oct 2016 13:57:35 +0000 (16:57 +0300)
committerMikko Rasa <tdb@tdb.fi>
Mon, 3 Oct 2016 13:57:35 +0000 (16:57 +0300)
Otherwise the swap_buffers from rendering the mirror view will interfere
with submitting VR frames.  The OpenVR library internally syncs to the
HMD's vertical refresh.

source/openvr/openvrcombiner.cpp

index fa5a8ac45edb9daba2398c04b68107c8041be485..20b485eac1a9cf3401bae393dbb422b3cdad2f82 100644 (file)
@@ -25,6 +25,7 @@ OpenVRCombiner::OpenVRCombiner(OpenVRSystem &d, GL::View &v):
        Frustum right_frustum = Private::get_projection(vr::Eye_Right);
        configure_eye_frustums(left_frustum, right_frustum);
 
+       view.get_context().set_swap_interval(0);
        set_mirroring(true);
 }