2 USING: kernel arrays sequences math math.order qualified
3 sequences.lib circular processing ui newfx processing.shapes ;
5 IN: processing.gallery.trails
7 ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
9 ! Example 33-15 from the Processing book
11 ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
13 : point-list ( n -- seq ) [ drop 0 0 2array ] map <circular> ;
15 ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
17 : dot ( pos percent -- ) 1 swap - 25 * 5 max circle ;
30 ! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
45 : go ( -- ) [ go* ] with-ui ;