Add getFrag parser for WebGL fragment shader
This commit is contained in:
parent
f280f25cd7
commit
a05cb5e6ff
1 changed files with 3 additions and 0 deletions
|
@ -65,6 +65,9 @@ make.webgl = {
|
||||||
}
|
}
|
||||||
return names
|
return names
|
||||||
},
|
},
|
||||||
|
parseFrag: (shader) => {
|
||||||
|
return shader.match(/(gl_Frag[^[ =]+)/gm)
|
||||||
|
},
|
||||||
randomBitmask: () => {
|
randomBitmask: () => {
|
||||||
return parseInt((random.subset([1, 0], 8).join('')))
|
return parseInt((random.subset([1, 0], 8).join('')))
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue