mirror of
https://github.com/astromaddie/HaloCE-VR.git
synced 2026-10-17 15:00:13 +02:00
The game side of single-pass stereo: with vr.multiview (on by default) a stereo frame's two eye windows become one, drawn from between the eyes with a frustum covering both (culling and visibility once for the pair), and the windows after it move up. rasterizer_set_frustum_z then gives the vertex programs each eye's camera: view 0's in c[-96..-89] as before, view 1's through halo_vr_set_view1_vertex_constants, both with the call's near and far. The pass draws into d3d8_gl.c's two-layer target (halo_vr_multiview_begin/end, then halo_vr_resolve_multiview); if the driver refuses it, that frame draws the left eye alone and the eyes are drawn one at a time from then on. The hidden-area mask is left out of the one pass for now. Non-VR builds keep rasterizer_set_frustum_z as it was.