yum-mirror/glslang
git clone https://git.yummers.dev/yum-mirror/glslang
c190d5bc
main
1#version 310 es 2precision mediump float ; 3 4struct S { 5float buff [ 10 ]; 6}; 7 8layout (std430, binding = 2 ) readonly buffer RoBuff { 9float buff_ro [ 10 ]; 10S s_ro ; 11} ro_buffer; 12 13layout (std430, binding = 2 ) buffer Buff { 14float buff [ 10 ]; 15S s ; 16} non_ro_buffer; 17 18void non_ro_fun( float [ 10 ] buff) { } 19void non_ro_funf( float el) { } 20void non_ro_funS( S s) { } 21 22out vec4 fragColor; 23 24void main() 25{ 26S s; 27 28non_ro_fun(s. buff ); 29non_ro_funf(s. buff [ 3 ]); 30non_ro_funS(s); 31 32non_ro_fun(non_ro_buffer. buff ); 33non_ro_fun(non_ro_buffer. s . buff ); 34non_ro_funf(non_ro_buffer. buff [ 3 ]); 35non_ro_funf(non_ro_buffer. s . buff [ 3 ]); 36non_ro_funS(non_ro_buffer. s ); 37 38non_ro_fun(ro_buffer. buff_ro ); 39non_ro_fun(ro_buffer. s_ro . buff ); 40non_ro_funf(ro_buffer. buff_ro [ 3 ]); 41non_ro_funf(ro_buffer. s_ro . buff [ 3 ]); 42non_ro_funS(ro_buffer. s_ro ); 43}