Use vertex pulling for clouds

This commit is contained in:
2025-11-12 19:57:07 +00:00
parent ce1937c78e
commit 409180959c
11 changed files with 202 additions and 107 deletions
+1 -4
View File
@@ -1,7 +1,5 @@
#version 450 core
//struct PosColNorm { vec4 pos; vec4 norm;uint col; uint dummy; };
struct PosColNorm { vec4 pos; uint norm;uint col; };
// I don't know if the dummy is necessary
struct PosColNorm { vec4 pos; uint norm; uint col; };
layout (std140, binding = 0) uniform TheMat { mat4 theMat; } ;
layout (std430, binding = 3) readonly buffer Data { PosColNorm data[]; };
layout (std430, binding = 4) readonly buffer Indices { uint indices[]; };
@@ -12,7 +10,6 @@ void main() {
vPos = data[indices[gl_VertexID]].pos;
vCol = unpackUnorm4x8(data[indices[gl_VertexID]].col);
vNorm = unpackSnorm4x8(data[indices[gl_VertexID]].norm);
//vNorm = n *2 - vec4(1,1,1,1);
gl_Position = theMat * vec4(vPos.xyz,1);
}
//layout (location = 0) in vec4 pos;