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

Vulkan: GPUParticles create artifacts upon instantiating due to scale interpolation issues #59072

Closed
Tracked by #61067
jar-works opened this issue Mar 12, 2022 · 12 comments · Fixed by #70418
Closed
Tracked by #61067

Comments

@jar-works
Copy link

Godot version

4.0 Alpha 4

System information

Windows 10

Issue description

So there are some artifacts when spawning GPUParticles3D (not 2D) specifically. I've tried on Alpha 3 and the issue is not present. I also have some CPUParticles3D working along side these and they also do not seem to create this issue.

Video 1
Video 2

It is only happens a few times during play, and goes away after spawning them in a few times more.

Specs:
i7-9700k
RTX 2060 (Zotac) => Running GeForce Diver Version 511.79

Steps to reproduce

Instantiate a GPUParticle3D

Minimal reproduction project

TestingParticles2.zip

@Calinou Calinou added this to the 4.0 milestone Mar 12, 2022
@Calinou Calinou changed the title GPUParticles create artifacts upon instantiating (Godot 4 Alpha 4) Vulkan: GPUParticles create artifacts upon instantiating (Godot 4 Alpha 4) Mar 12, 2022
@Whimfoome
Copy link

Maybe related to #56691

@TechnoPorg
Copy link
Contributor

This may also be related to, or even a duplicate of, #54771.

@lufog
Copy link
Contributor

lufog commented Mar 31, 2022

I have similar problem with GPUParticles2D on Godot v4.0.alpha.custom_build [155a94f]

2022-04-01.02-32-03.mp4

Test project: https://github.com/lufog/godot-asteroids

Should I open a new issue, or it's the same problem?

@Calinou
Copy link
Member

Calinou commented Apr 1, 2022

Should I open a new issue, or it's the same problem?

This is likely the same issue – we can consolidate it here.

@jivvy
Copy link

jivvy commented Apr 14, 2022

Godot v4.0.alpha.custom_build [12cb05b]

  • Particles sometimes flash again when on an object that was queue_free()'d:
godot_gpuparticles2d_disappearing_flash.mp4
  • When there are lots of particles, rendering begins flashing. Sometimes it will calm down after a while, as showed in the video, sometimes it will continue a long time.
godot_gpuparticles2d_artifacts_shorter.mp4

I also noticed particles from a previous run of the game sometimes flashed.

How observed:

  1. Set particle color to white, ran the game, observed the flashing described in the first point above
  2. Set particle color to red, ran game, and saw white particles flashing at the beginning.

Test project:
GD4_GPUParticles2D_Artifacts_Jivvy.zip

@JoanPotatoes2021
Copy link

JoanPotatoes2021 commented Apr 19, 2022

Sadly on v4.0.alpha6.official [e4f0fc5] I am facing the same issue, I tried creating a minimal project to post it but I couldn't reproduce it isolated, however I could capture the bug on screen, tested on a GTX 1050 TI running on win10:

ParticleFlickerFlash-1

This weird scale flicker that grows huge is abnormal and does not have any correlation to the particle parameters or the shader, I have tried a lot of tests on this project to see if I could fix it (chaning all particle parameters and testing the shader the heck out), the only thing that seemd to fix it was to set Vsync on, I don't know if it has something to do with fast frames over 60 fps and delta, on this specific project it's running about 270-360 fps without vsync, it also happens more frequently when I move my character, the camera is also not inside the kinematicbody3D and I am constantly lerping various velocities on the physics process in this project.

Edit: And I forgot to mention that I am instantiating the particle for every shot, mainly because I didn't like animating emitting or the visibility on some effects.

@Calinou Calinou changed the title Vulkan: GPUParticles create artifacts upon instantiating (Godot 4 Alpha 4) Vulkan: GPUParticles create artifacts upon instantiating due to scale interpolation issues Apr 19, 2022
@JoanPotatoes2021
Copy link

#56886 (comment) Linking similar issue

@RexTheWho
Copy link

Recently experienced this issue (2D and 3D shown already in this issues thread)
I have found a workaround that seems to have stopped the blinding flashes, setting preprocess to even 0.01 seems to stop the issue- tho I'm not aware of what issues might come from doing that.

Thought I would mention it in case it's a helpful lead for finding the issue or saves someones eyes in the meantime.

@Zireael07
Copy link
Contributor

Seeing something similar in my own project, will have to try the tip above because a super-sized spark is not a pleasant sight

@JoanPotatoes2021
Copy link

JoanPotatoes2021 commented Apr 21, 2022

Recently experienced this issue (2D and 3D shown already in this issues thread) I have found a workaround that seems to have stopped the blinding flashes, setting preprocess to even 0.01 seems to stop the issue- tho I'm not aware of what issues might come from doing that.

Thought I would mention it in case it's a helpful lead for finding the issue or saves someones eyes in the meantime.

Yea this helps, but I ocassionally still get some flickers, preprocess advances the particle life through that amount when it's emitted, so it starts a little more 'older' in lifetime terms, if you increase pre-process past the lifetime, the particle will not even appear on screen, unless you have a special animated sequence or very short lifetime like a fast particle, this will not work.

@vassembly
Copy link

can confirm on 4.0beta8

2022-12-15.21-39-05.mp4

pierpo added a commit to bear-minimum-studio/nightbear that referenced this issue Dec 19, 2022
@clayjohn
Copy link
Member

Tracked this down. It is a regression from #58491

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.