ZXASCII
AUTO -1
PROG demos:graphics/circle_illusion
CHANGED FALSE
10 paper 8: ink 8: cls:
 np=8,i=0,cr=15,hh=scrh/2,hw=scrw/2,mr=hh-cr*2:
 do:
    circle ink 239;hw,hh,hh-8 fill:
    for f=0 to np*2-1:
       a=(pi/np)*f:
       draw ink 235;mr*sin a+hw,mr*cos a+hh to hw,hh:
    next f:
    circle ink 239;hw,hh,40 fill:
    for f=0 to np-1:
       a=(pi/np)*f,
       r=sin(i+a)*mr,
       x=r*sin a+hw,
       y=r*cos a+mr+cr*2:
       circle over 1;x,y,cr fill:
    next f:
    i+=.03:
    wait screen:
    cls:
 loop
