Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"compute_list_dispatch: Uniforms were never supplied for set (3) at the time of drawing" Error when rapidly deleting many local to scene particle systems #82257

Closed
supremecool185 opened this issue Sep 24, 2023 · 2 comments · Fixed by #82431

Comments

@supremecool185
Copy link

Godot version

4.1.1.stable

System information

Godot v4.1.1.stable - Windows 10.0.19045 - Vulkan (Forward+) - dedicated NVIDIA GeForce RTX 3070 Ti (NVIDIA; 31.0.15.3623) - Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz (8 Threads)

Issue description

If you instantiate a large number of GPUParticle2D nodes that use a ParticleProcessMaterial rather than a ShaderMaterial, and set the "Local to Scene" variable to true, if those nodes get deleted by calling queue_free() it will cause the error message:
compute_list_dispatch: Uniforms were never supplied for set (3) at the time of drawing, which are required by the pipeline
Additionally whenever this error message appears there will also be visual artifacts of particles scaling across the whole screen.

Attempting to replicate this I set up a script that would instantiate a new particle system every frame in _process() and then queue_free() it after some number of seconds, however this does not actually cause the error. The particle systems must (as far as i know) be instantiated in _input() rather than _process().

Steps to reproduce

  1. Create a GPUParticles2D node
  2. Set its ProcessMaterial as a new ParticleProcessMaterial
  3. Set the ProcessMaterial variable "Local to Scene" to true
  4. Add a script to the GPUParticles node that calls queue_free() after some amount of time
  5. Create a node that instantiates a copy of the GPUParticles node every time a keyboard input is received in _input()
  6. Run this scene and mash keyboard buttons to generate a large number of GPUParticle nodes
  7. See that if multiple nodes get deleted in quick succession by queue_free() the particles will artifact and generate error codes

Minimal reproduction project

Minimal reproduction project.zip
Run the scene named "spawner.tscn" and mash keyboard inputs to see the error

@bitsawer
Copy link
Member

Looks similar to #77759. I guess it was not fixed by #79849 and was a separate issue. Let's keep this issue open as now we have a good test project.

I can confirm this, looks like the error triggers here:

ERR_FAIL_MSG("Uniforms were never supplied for set (" + itos(i) + ") at the time of drawing, which are required by the pipeline");

@Calinou
Copy link
Member

Calinou commented Oct 5, 2023

I can confirm this on 4.2.dev fe8a58b (Linux, NVIDIA 535.113.01).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants