diff options
author | Mitya Selivanov <automainint@guattari.tech> | 2023-10-01 09:48:35 +0200 |
---|---|---|
committer | Mitya Selivanov <automainint@guattari.tech> | 2023-10-01 09:48:35 +0200 |
commit | 6504efe0032ada117b09f1130cf9841b64c54aa7 (patch) | |
tree | a1185c46a38f08894d44d4c18a577907fb505d13 /source | |
parent | 6f3be6d907f9dad9bd0d1b725d3609be0e7ce4df (diff) | |
download | saw-6504efe0032ada117b09f1130cf9841b64c54aa7.zip |
emscripten glClearDepth fix
Diffstat (limited to 'source')
-rw-r--r-- | source/saw/main.c | 4 |
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); |