aboutsummaryrefslogtreecommitdiff
path: root/src/shader/code/extra.glsl
diff options
context:
space:
mode:
authorAdrian Kummerlaender2019-11-08 23:02:47 +0100
committerAdrian Kummerlaender2019-11-08 23:02:47 +0100
commitd864699c5ddd744ee7376c0d752b6bbb771429a2 (patch)
tree9dd8973b17a0617ce595c2b92ec1d0faa8388083 /src/shader/code/extra.glsl
parent35e2c7a949dedf3221887ffdc14dddb4c5e84f4c (diff)
downloadcompustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar.gz
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar.bz2
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar.lz
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar.xz
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.tar.zst
compustream-d864699c5ddd744ee7376c0d752b6bbb771429a2.zip
Update lattice multiple times per frame
Controlled by `--lupf` _Lattice updates per frame_ MLUPS are now calculated and displayed. While performance is still bad compared to a optimized GPU implementation (such as [1] or [2]) this improves the situation. [1]: https://tree.kummerlaender.eu/projects/symlbm_playground/ [2]: https://code.kummerlaender.eu/boltzgen/about/
Diffstat (limited to 'src/shader/code/extra.glsl')
-rw-r--r--src/shader/code/extra.glsl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/shader/code/extra.glsl b/src/shader/code/extra.glsl
index b8483ae..4b149fb 100644
--- a/src/shader/code/extra.glsl
+++ b/src/shader/code/extra.glsl
@@ -9,7 +9,7 @@ layout (std430, binding=4) buffer bufferExtra { float extraCells[]; };
uniform uint nX;
uniform uint nY;
-const float convLength = 1.0 / float(max(nX,nY));
+const float convLength = 1.0 / float(min(nX,nY));
/// Array indexing