
一、首先修改你的index.html文件
请注意主要在html页面修改添加的是需要加选择项:"triangle-list"和"triangle-strip",如果你不理解这两个关键词,移步查看webgpu文档:https://www.orillusion.com/zh/webgpu.html#primitive-state 的第10.3.2节Primitive state查看原始状态可以创建哪些图元。

1
2
3
4
5 WebGPU Step-by-Step 6
6
7
8
9
10
11 12
Create Triangle Primitives
13
14
19
20
21
22
23
24