summaryrefslogtreecommitdiffhomepage
path: root/src/core.c
diff options
context:
space:
mode:
authorRay <[email protected]>2016-06-17 13:54:45 +0200
committerRay <[email protected]>2016-06-17 13:54:45 +0200
commit24c9b1f717bd9a6510667907614928188a6b6a6f (patch)
tree4dbed77c7b27390d28bc0977f0588a9f8d7d9aa7 /src/core.c
parent9fdf4420d5354c32394246703015a686df8135ce (diff)
downloadraylib-24c9b1f717bd9a6510667907614928188a6b6a6f.tar.gz
raylib-24c9b1f717bd9a6510667907614928188a6b6a6f.zip
Improving Oculus Rift example...
Under design... looking for the easiest and most comprehensive way for the user to use VR...
Diffstat (limited to 'src/core.c')
-rw-r--r--src/core.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/core.c b/src/core.c
index 7c2dbcb9..eef81bad 100644
--- a/src/core.c
+++ b/src/core.c
@@ -606,6 +606,8 @@ void Begin3dMode(Camera camera)
rlMultMatrixf(MatrixToFloat(cameraView)); // Multiply MODELVIEW matrix by view matrix (camera)
rlEnableDepthTest(); // Enable DEPTH_TEST for 3D
+
+ //if (vrEnabled) BeginVrMode();
}
// Ends 3D mode and returns to default 2D orthographic mode
@@ -1015,6 +1017,14 @@ Matrix GetCameraMatrix(Camera camera)
return MatrixLookAt(camera.position, camera.target, camera.up);
}
+// Update and draw default buffers vertex data
+// NOTE: This data has been stored dynamically during frame on each Draw*() call
+void DrawDefaultBuffers(void)
+{
+ rlglUpdateDefaultBuffers(); // Upload frame vertex data to GPU
+ rlglDrawDefaultBuffers(); // Draw vertex data into framebuffer
+}
+
//----------------------------------------------------------------------------------
// Module Functions Definition - Input (Keyboard, Mouse, Gamepad) Functions
//----------------------------------------------------------------------------------