fix spacebar bug, fix ios depth buffer error, parallelize raytracing

This commit is contained in:
2019-01-12 18:01:23 +01:00
parent d5b5946b3d
commit e95421c2ed
4 changed files with 13 additions and 2 deletions

View File

@@ -2208,7 +2208,7 @@ void Canvas::draw_objects(std::function<void(const glm::mat4& camera, const glm:
GLuint rboID;
glGenRenderbuffers(1, &rboID);
glBindRenderbuffer(GL_RENDERBUFFER, rboID);
glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT, layer.w, layer.h);
glRenderbufferStorage(GL_RENDERBUFFER, GL_DEPTH_COMPONENT24, layer.w, layer.h);
glBindRenderbuffer(GL_RENDERBUFFER, 0);
glm::mat4 proj = glm::perspective(glm::radians(90.f), 1.f, .01f, 1000.f);