diff options
author | Andreas Grois <andi@grois.info> | 2018-03-10 13:55:50 +0100 |
---|---|---|
committer | Andreas Grois <andi@grois.info> | 2018-03-10 13:55:50 +0100 |
commit | a0afe4bf8c011222b85c481ae209b09f75189858 (patch) | |
tree | 16c8fa87fa5b5113b2186adfc0b58f3b3549ac90 /BuddhaTest/Shaders/BuddhaFragment.glsl | |
parent | 710c12067531e6e05280d081203aeb3b945669a9 (diff) |
Reduce buffer size by a factor of 2 (image is symmetric)
Diffstat (limited to 'BuddhaTest/Shaders/BuddhaFragment.glsl')
-rw-r--r-- | BuddhaTest/Shaders/BuddhaFragment.glsl | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/BuddhaTest/Shaders/BuddhaFragment.glsl b/BuddhaTest/Shaders/BuddhaFragment.glsl index 4978765..cb09628 100644 --- a/BuddhaTest/Shaders/BuddhaFragment.glsl +++ b/BuddhaTest/Shaders/BuddhaFragment.glsl @@ -14,7 +14,7 @@ layout(std430, binding=2) buffer renderedData uvec3 getColorAt(vec2 fragCoord)
{
uint xIndex = uint(max(0.0,(fragCoord.x+1.0)*0.5*width));
- uint yIndex = uint(max(0.0,(fragCoord.y+1.0)*0.5*height));
+ uint yIndex = uint(max(0.0,abs(fragCoord.y)*height));
uint firstIndex = 3*(xIndex + yIndex * width);
return uvec3(counts_SSBO[firstIndex],counts_SSBO[firstIndex+1],counts_SSBO[firstIndex+2]);
}
|