You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
instantiating particles occasionally leaves visual artifacts and/or effects shadows for a single frame.
instantiating a lot of GPUParticle3D at once makes it more obvious, bellow I instantiate 20 new GPUParticle3D on the left side every .05 seconds and queue_free after 1 second. Having the same total amount of active emitters running does not give the same artifacts as instancing and freeing.
Just posting an ugly hack for this issue. Apparently this was fixed in a project I'm working in by restarting the GPUParticles (to delete all current particle geometries), and giving sufficient time between stop emitting particles and deleting the scene.
Ugly code:
func _kill() -> void:
# This is a fix for the flickering problem of particles: https://github.com/godotengine/godot/issues/65443
# We have to restart the particles and give sufficent amount of time before deleting the node,
# so particles won't flicker on the last position they were rendered
$Bullet/GPUParticles3D.restart()
$Bullet/GPUParticles3D.emitting = false
await get_tree().physics_frame
await get_tree().physics_frame
await get_tree().physics_frame
queue_free()
Godot version
4.0 alpha 15
System information
Fedora x11 NVIDIA GeForce GTX 970
Issue description
instantiating particles occasionally leaves visual artifacts and/or effects shadows for a single frame.
instantiating a lot of GPUParticle3D at once makes it more obvious, bellow I instantiate 20 new GPUParticle3D on the left side every .05 seconds and queue_free after 1 second. Having the same total amount of active emitters running does not give the same artifacts as instancing and freeing.
Screencast.from.09-06-2022.02.27.49.PM.webm
Steps to reproduce
GPUparticle3D.zip
Minimal reproduction project
No response
The text was updated successfully, but these errors were encountered: