How to build a material

when i code ,i always am confused with material,i do not how the vertex shader paramer such as attribute position etc is built,and how the fragment shader paramer is built

Hi @xiaozhiquan, welcome to the community!

Along with the Material documentation, you can find more information at the Fabric wiki page. There is also some information about the vertex and fragment shader structs in the Custom Shader Guide. For example, the Attributes struct table gives some details about the different position attributes.

We always welcome suggestions on how to improve our documentation. If something is still not clear, please let us know!