summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source/saw/main.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/saw/main.c b/source/saw/main.c
index 3add53a..d67efd1 100644
--- a/source/saw/main.c
+++ b/source/saw/main.c
@@ -1530,7 +1530,11 @@ static void saw_frame(void) {
glViewport(0, 0, frame_width, frame_height);
glClearColor(.15f, .12f, .10f, 1.f);
+#ifdef __EMSCRIPTEN__
+ glClearDepthf(1.f);
+#else
glClearDepth(1.);
+#endif
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT |
GL_STENCIL_BUFFER_BIT);