Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- xed=720:yed=480:wdwd=1:frmall=2000:frmct=0:ivbl=0
- randomize
- function rndfloat(a):rndfloat=(rnd(a*1000))/1000:end function
- setdisplay(xed,yed,32,wdwd):paper(8^8-1):ink(0):pen(0):cls
- paper (rgb(rnd(255),rnd(255),rnd(255))):cls
- setcaption("Spirographics (...?)")
- while frmct<frmall
- ink (rgb(rnd(255),rnd(255),rnd(255)))
- r0=rndfloat(15):r1=rndfloat(5):r2=rndfloat(5)
- fc=rndfloat(60):st=rndfloat(10)/1000
- xq0=rnd(xed):yq0=rnd(yed)
- inic=0:fi=80:pi=3.141592
- xol=0:yol=0:mol=0
- for i=inic to fi step st
- a0=(i/r0)*(2*pi):a1=((i/r1)*(2*pi))*-1
- x1=xq0+(sin(a0)*((r0-r1)*fc)):y1=yq0+(cos(a0)*((r0-r1)*fc))
- x2=x1+(sin(a1)*((r2)*fc)):y2=y1+(cos(a1)*((r2)*fc))
- if mol=0 then: mol=1:xol=x2:yol=y2
- else: line (xol,yol,x2,y2):xol=x2:yol=y2
- end if
- if key(k_esc)<>0 then:end:end if
- if key(k_delete)<>0 then:cls:end if
- ivbl+=1
- if ivbl>2048 then:
- 'waitvbl
- grab (1,0,0,xed,yed):saveimage ("tmp.bmp",1):shell("convert tmp.bmp frm"+str$(frmct)+".jpg")
- frmct+=1:ivbl=0
- end if
- next
- wend
- shell ("ffmpeg -i frm%d.jpg -target ntsc-dvd final.vob")
- shell ("rm *.jpg")
- '- sudo apt-get install sdlbasic ffmpeg imagemagick
- '- sudo apt-get install libcdaudio1 gstreamer0.10-ffmpeg libxine1-ffmpeg libenca0 libcdaudio1 libdvdread4 libdvdnav4
- '- sudo apt-get install gstreamer0.10-plugins-bad gstreamer0.10-ffmpeg gstreamer0.10-plugins-ugly gstreamer0.10-plugins-bad-multiverse
- '- sudo apt-get install libavutil49 libavcodec52 gstreamer0.10-plugins-bad
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement