Vertex Shader (vertex shader) is a technical term that is extremely important in rendering and optimizing game graphics (technical art). A program that is executed on each "vertex" that makes up a 3D model, and performs coordinate transformation, vertex color processing, and adds animation such as waves and deformation to the shape.

Real-world analogy: A sculptor who transforms doll joints and clay shapes by connecting them with his hands

Vertex shader is a "modeler who pinches the corners (vertices) of a clay work (3D mesh) placed in 3D space one by one and transforms the shape in real time". It calculates where the clay should be when viewed from the camera (coordinate transformation), and when the wind blows, it processes the shape by pulling the right vertex a little (wind swaying) dozens of times a second at ultra-high speed. At this point, I have not applied the color yet, and am only responsible for adjusting the frame and shape.

Vertex Shader concept infographic diagram

Figure: An infographic that clearly illustrates the basic processing flow and mechanism of Vertex Shader (vertex shader) in Japanese notation

Detailed mechanism and operating principle

In the vertex shader (or the Vertex stage of Shader Graph), use a sine wave or noise function to displace the local coordinates of the vertex position in real time.