From 58775a6c6767ffb69449f0f6ba823bcd3d432545 Mon Sep 17 00:00:00 2001 From: David Snopek Date: Sat, 21 Oct 2023 16:49:24 -0500 Subject: [PATCH] Fix `GPUParticles3D` on the Meta Quest 2 with OpenGL renderer --- drivers/gles3/storage/particles_storage.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gles3/storage/particles_storage.cpp b/drivers/gles3/storage/particles_storage.cpp index 1caa3bbe353f..e263acf88b1f 100644 --- a/drivers/gles3/storage/particles_storage.cpp +++ b/drivers/gles3/storage/particles_storage.cpp @@ -818,6 +818,7 @@ void ParticlesStorage::particles_set_view_axis(RID p_particles, const Vector3 &p } glEnable(GL_RASTERIZER_DISCARD); + glBindFramebuffer(GL_FRAMEBUFFER, 0); _particles_update_instance_buffer(particles, axis, p_up_axis); glDisable(GL_RASTERIZER_DISCARD); } @@ -1001,6 +1002,7 @@ void ParticlesStorage::_particles_update_instance_buffer(Particles *particles, c void ParticlesStorage::update_particles() { glEnable(GL_RASTERIZER_DISCARD); + glBindFramebuffer(GL_FRAMEBUFFER, 0); GLuint global_buffer = GLES3::MaterialStorage::get_singleton()->global_shader_parameters_get_uniform_buffer();