my little 5 cent for this night
no really time last day to create new things... but I have played around with this liongfx example with well known coding stuff (fbgfx!), translated for my purpose and so it looks like this one...
[code=thinbasic]'Plasma-like effect with liongfx
uses "liongfx", "console"
Dim T1, T2 As QUAD
Dim w,h As Double
w=400
h=350
'---Initialize hi resolution timer
HiResTimer_Init
liongfx_ScreenRes(w,h,32,2)
Dim x,y,page As Double
Dim c,t As Double
T1 = HiResTimer_Get
t=t+1
For x = 0 To w
For y = 0 To h
c=(Cos((x+y+t)/100)+Cos((x-t)/100)+Cos((y-t)/100)+Cos((x-y+t)/100))*2+Sin(t/100)*15
liongfx_PSet(x,y,Rgb(Sin(c)*64+128,Cos(c)*64+128,Cos(-c/2)*64+12)
liongfx_PSet(x,y,Rgb(Cos(c)*32+128,4*rnd*Cos(c)*32+128,log(-c/2)*64+12)
'liongfx_Circle rnd(100,540), rnd(10,380), rnd(10,200), rnd(1, RGB(255,255,255))
Next
printl " just an liongfx learning script " + int(rnd(1)*400), "Ciao Julius Cesar! " + int(rnd(1)*400)
Next
T2 = HiResTimer_Get
MSGBOX 0, "Elapsed time in microseconds: " & format$((t2-t1)/1000000, "#.000") '- (t2-t1)/1000000
sleep 5000
page=-page+1
liongfx_ScreenSet(page,-page+1)
'printl
'printl "press any key to exit"
'waitkey
stop[/code]
ok, I have included two different functions, not very new things, but was a good exercise to learn for me... and you can test also your machine for speed
more to come, hope it works, good night, Lionheart
Bookmarks