Open afonsolage opened 2 years ago
I also encountered this, alternative to this is writing a pipeline, which is a lot boilerplate. Here it is for reference: https://discord.com/channels/691052431525675048/970964103516532746/970998522679816222
Seems to be fixed in 0.10. Am I mistaken? in mesh.wgsl
I see all vertex attributes are conditionally added.
struct Vertex {
#ifdef VERTEX_POSITIONS
@location(0) position: vec3<f32>,
#endif
#ifdef VERTEX_NORMALS
@location(1) normal: vec3<f32>,
#endif
#ifdef VERTEX_UVS
@location(2) uv: vec2<f32>,
#endif
#ifdef VERTEX_TANGENTS
@location(3) tangent: vec4<f32>,
#endif
#ifdef VERTEX_COLORS
@location(4) color: vec4<f32>,
#endif
#ifdef SKINNED
@location(5) joint_indices: vec4<u32>,
@location(6) joint_weights: vec4<f32>,
#endif
};
Bevy version
0.7
What you did
Created a custom material without using
Vertex_UV
attributeWhat went wrong
The custom material requires vertex
POSITION
,NORMAL
andUV
attributes to be set on Mesh even if the custom material layout doesn't specifies so. This seems to be a requirement of the mesh pipeline.Additional information
This was first reported and discussed here
superdump
cart