material-maker/addons/material_maker/nodes/weave.mmg

1 line
579 B
Plaintext

{"name":"weave","node_position":{"x":0,"y":0},"parameters":{"columns":4,"rows":4},"shader_model":{"global":"float weave(vec2 uv) {\n\tvec2 v = sin(3.1415892*vec2(uv.x+floor(uv.y), 1.0+uv.y+floor(uv.x)));\n\treturn max(v.x, v.y)*0.5+0.5;\n}","inputs":[],"instance":"","name":"Weave","outputs":[{"f":"weave(vec2($columns, $rows)*$uv)","type":"f"}],"parameters":[{"default":0,"label":"","max":32,"min":2,"name":"rows","step":1,"type":"float","widget":"spinbox"},{"default":0,"label":"","max":32,"min":2,"name":"columns","step":1,"type":"float","widget":"spinbox"}]},"type":"shader"}