Godot Version
4.3 Stable
Question
I am using the new Godot 4.3 stable release, I am using CPUParticles2D in my game. When I export the game to HTML5 the particles are gone. They are not running in any browser on any device.
I got it working for me on 4.3, did you enable Top Level in the visibility section of the particle?
(I figured that out using the answer here) GPUParticles2D appearing in editor, but not in game - #2 by FreakyGoose
1 Like
Thanks, but that didnāt work in my case. I am using CPUParticles2D. it doesnāt show on html5 build.
gl_compatibility renderer mode? what kind of particle you are trying to show?
yes, gl_compatibility renderer mode. just a simple blast effect, any particle configuration generates the same result for me, even the asset store particle projects arenāt working on web as well.
sounds like a bug then, have you tried on different browsers/devices
Ran into this issue just now. Appears to be an odd bug related to only AMD graphics cardsā¦
Happening on GPU and CPU particle systems
opened 11:36AM - 19 Aug 24 UTC
closed 10:21AM - 02 Sep 24 UTC
bug
platform:web
topic:rendering
confirmed
regression
topic:particles
### Tested versions
- Reproducable in Godot 4.3.dev6 -> Godot 4.3
### Systā¦ em information
Windows 10, AMD Ryzen 5 4500U (GPU: AMD Radeon RX Vega 6 (Ryzen 4000/5000))
### Issue description
**EDIT:**
**Solution 1**
-
I found a settings in Chrome that actually fixes the `GPUParticles`: (chrome://flags/)

This is set to `Default`,- if it is set to `OpenGL`, everything works. If it is set to `D3D11` or `D3D11on12`, it doesn't for the below mentioned AMD hardware combinations.
As also written in the description, `D3D11` seems to be used as the default for most Windows machines, but it will break `GPUParticles` for some hardware combinations.
**Solution 2**
-
Turning off `graphic acceleration` in Google Chrome fixes the issue as well (although `GPUParticles` will lag now)

---
- After testing my game on different Hardware, there seems to be a problem with AMD GPUs when rendering `GPUParticles` on a Web Build.
- The Browser doesn't matter, it doesn't work with every Browser (Edge, Chrome, Firefox)
- There are no errors in the console
- There is still the typical particle render lag the first time it should be shown, but nothing is rendered
`GPUParticles` are not rendered in a Web Build for the following Hardware:
```
CPU: AMD Ryzen 5 4500U
Integrated GPU: AMD Radeon RX Vega 6
```
```
CPU: AMD Ryzen 5 5600U
Integrated GPU: AMD Radeon RX Vega 7
```
```
CPU: AMD Ryzen 7 5825U
Integrated GPU: AMD Radeon RX Vega 8
```
This combination however works:
```
CPU: AMD Ryzen 7 5700U
Integrated GPU: AMD Radeon RX Vega 8
```
The native binary works and renders the `GPUParticles` (which uses Forward+ (Vulkan)).
It seems that every other Hardware works as of now.
Tested with Intel (iGPU) and Nvidia GPU.
If there is anything I can try, let me know.
### Steps to reproduce
- Open the project, particles should not visible in the editor, also when running
OR
- Run in your Browser: https://maran23.itch.io/space-heist - Start a level, compare with the screenshots
### Minimal reproduction project (MRP)
[ParticleBug.zip](https://github.com/user-attachments/files/16789243/ParticleBug.zip)
OR
Open and run in your Browser: https://maran23.itch.io/space-heist
A fix has been completed, but is not yet in an official release.
godotengine:master
ā Maran23:gpuparticles-amd-fix
opened 10:14PM - 31 Aug 24 UTC
Fixes: https://github.com/godotengine/godot/issues/95797
Using the algorithm ā¦ (bottom of the paper) as proposed by @clayjohn: https://www.researchgate.net/publication/362275548_Accuracy_and_performance_of_the_lattice_Boltzmann_method_with_64-bit_32-bit_and_customized_16-bit_number_formats
Made sure that my fix does not cause any regressions (see project below):
- https://github.com/godotengine/godot/issues/72882
- https://github.com/godotengine/godot/issues/71731
- https://github.com/godotengine/godot/issues/66462
- https://github.com/godotengine/godot/issues/66459
- https://github.com/godotengine/godot/issues/73320
This should be reviewed by someone much more familiar than me.
`GPUParticles` now work fine for older AMD GPUs as specified in the issue, as well as e.g. my much newer GPU, that did not suffer from this problem (works before, works after).
I plan to test this on other GPUs as well soon.
---
cc @Alex2782 - testing on an Adreno 3xx device would be nice as well :)
cc @JonqsGames - since you did the initial change that caused this 'regression' in https://github.com/godotengine/godot/pull/72914
cc @clayjohn - as you wrote and reviewed most of the OpenGL stuff :D
---
Project for testing, that contains all issues we once had regarding the conversion:
[ParticleBug.zip](https://github.com/user-attachments/files/16830007/ParticleBug.zip)
Everything is named like to GH issue and it is 'linked' in the description so you can check everything fast.
|  |  |
---
Tested project above on:
- AMD Ryzen 5 4500U with integrated AMD Radeon RX Vega 6 (broken before)
- Intel(R) Core(TM) i5-4670 CPU with dedicated AMD Radeon RX 580 Series (broken before)
- AMD Ryzen 9 5900X with dedicated AMD Radeon RX 6900 XT
- AMD Ryzen 7 5800X3D with dedicated NVIDIA GeForce RTX 4070 Ti
One of my CPU Particles did work in my game, and the other did not, which made me realize that one is using a custom texture and the other is just default stuff. I switched the broken one to use the default and it started working in the HTML build. However, it still didnāt have colors applied properly to it.
I tried on several different browsers and all had the same issue.
1 Like