int a = 1;
float v = uVertices[a];
报错:’[]’ : Index expression must be constant
uVertices 是一个uniform数组,怎么能通过变量索引它呢??
int a = 1;
float v = uVertices[a];
报错:’[]’ : Index expression must be constant
uVertices 是一个uniform数组,怎么能通过变量索引它呢??
cocos用的是glsl几呢?所以这个没解法了嘛
你要干嘛~
想把模型顶点传给片元着色器,做一些光追计算
期待楼主的光追效果~
不行哦~~