fn get_two_fibs(i: u32, j: u32) -> array<i32,2> {
// This constructor infers the element type and element count.
return array(first_fibs[i], first_fibs[j]);
}
however, in rust / wgpu I get the following error:
panicked at 'wgpu error: Validation Error
Caused by:
In Device::create_shader_module
note: label = `Shader`
Shader validation error:
┌─ Shader:72:17
│
72 │ var idx = ((idxs [ i32(face_idx) ]) >> vert_idx) % 8;
│ ^^^^^^^^^^^^^^^^^^^^^^ naga::Expression [30]
Entry point vs_main at Vertex is invalid
Expression [30] is invalid
The expression [27] may only be indexed by a constant
Is this a problem with wgpu-0.16.1, or is this a wgsl limitation ?