Add array size forum post

Vectornaut 2024-08-26 09:13:58 +00:00
parent 339631287f
commit 3be9c4479c

@ -7,6 +7,7 @@ Right now, we're drawing all the spheres in a single fragment shader. For each p
## Performance limits ## Performance limits
* **Array size.** As of commit `a34fd0f`, the SPHERE_MAX array size seems to affect frame rate a lot, even though we should only be using the first few elements of each array. Not sure whether this is coming from a depth-sorting bug, a memory handling detail, or something else. * **Array size.** As of commit `a34fd0f`, the SPHERE_MAX array size seems to affect frame rate a lot, even though we should only be using the first few elements of each array. Not sure whether this is coming from a depth-sorting bug, a memory handling detail, or something else.
* The logistics of initializing the arrays and working around register limits could be the problem, as described in [this forum post](http://gamedev.net/forums/topic/688607-glsl-shader-slow-when-having-too-big-arrays/5342186/).
* **Shader variables.** Browsers seem to limit the number of variables that fragment shaders can store. For example, see this [vulnerability report](https://issues.chromium.org/issues/40067239) and [code review](https://chromium-review.googlesource.com/c/angle/angle/+/4503753) for Chromium. This limit doesn't seem to be part of the OpenGL standard, so it's hard to pin down. * **Shader variables.** Browsers seem to limit the number of variables that fragment shaders can store. For example, see this [vulnerability report](https://issues.chromium.org/issues/40067239) and [code review](https://chromium-review.googlesource.com/c/angle/angle/+/4503753) for Chromium. This limit doesn't seem to be part of the OpenGL standard, so it's hard to pin down.
## References ## References