(bind-func generate_tri_uvws
(lambda (uvws:float* size:i64)
(let ((i 0) (k 0) (num (/ size 3)))
(dotimes (i num)
(set! k (* i 3))
(pset! uvws (+ k 0) (if (= 1 (% i 3)) 1.0 0.0))
(pset! uvws (+ k 1) (if (= 2 (% i 3)) 1.0 0.0))
(pset! uvws (+ k 2) 1.0))
void)))