7 memoryBarrierShared(); \
10 #extension GL_NV_mesh_shader : enable
12 layout(local_size_x = 32) in;
14 layout(max_vertices=MAX_VER) out;
15 layout(max_primitives=MAX_PRIM) out;
16 layout(triangles) out;
18 // test use of user defined interface out blocks:
20 // per-primitive block
21 perprimitiveNV layout(location=0) out myblock {
31 layout(location=20) out myblock2 {
39 uint iid = gl_LocalInvocationID.x;
40 uint gid = gl_WorkGroupID.x;
43 blk[iid+1].fArr[gid] = blk[iid].f;
44 blk[iid/2].pos.yzx = vec3(14.0, 15.0, 13.0);
45 blk[iid*2].posArr[1].yzw = blk[iid/2].pos;
46 blk[iid/4].m[2].wzyx = vec4(13.0, 14.0, 15.0, 16.0);
47 blk[iid].mArr[0][1][1] = blk[iid/4].m[2].w;
48 blk[iid*4].mArr[1][gid] = vec3(17.0, 18.0, 19.0);
52 blk2[iid].f = blk2[iid-1].f + 20.0;
53 blk2[iid].pos = vec4(21.0, 22.0, 23.0, 24.0);
54 blk2[iid+1].m[gid] = blk2[iid].pos;
55 blk2[iid+1].m[gid][2] = 29.0;
56 blk2[iid+2].m[3] = blk2[iid+1].m[gid];