25 March 2009, 18:04 | #1 |
Registered User
Join Date: Mar 2009
Location: moon
Posts: 373
|
Cracktro effect
Does anyone know what kind of effect is used in this cracktro (screenshot attached)? It zooms continously/infinitely into that cloud of colours while rotating. It runs smoothly on a regular A500, so it's probably nothing too computationally expensive.
|
25 March 2009, 18:44 | #2 |
Going nowhere
Join Date: Oct 2001
Location: United Kingdom
Age: 50
Posts: 8,986
|
I think its a fractal zoomer, and I think Bloodsuckers were first with it as well.
|
25 March 2009, 20:01 | #3 |
Registered User
Join Date: May 2004
Location: Somewhere secret
Age: 50
Posts: 364
|
I think it's more commonly known as a "Blitter Tornado" (!), and it's discussed in a lot of detail over at the ADA forums:-
http://ada.untergrund.net/forum/inde...&page=0#msg534 |
25 March 2009, 20:06 | #4 |
move.l #$c0ff33,throat
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
|
It's a blitter feedback effect and as far as I remember Tizzy/Shining made the first one in his Party'92 40k intro. Most known is the one by Dweezil though.
|
26 March 2009, 02:05 | #5 |
Join Date: Jul 2008
Location: Sweden
Posts: 2,269
|
Basically you use the blitter to modify one image frame into the next by skewing the image both horizontally and vertically to achieve rotation, typically in steps of 16 or 32 pixels. F.ex for a 256x256 pixel frame you would treat the frame as 16 columns and 16 rows, and add further displacement outwards to achieve the zooming effect. The latter is trickier to get working and I was only ever able to get rotation going when I tried this.
The jitter of pixels that give it the "fractal" look is simply aliasing that propagates from modifying one frame into the next in crude steps. If anyone has some commented source code for a working example I'd love to look at it. |
26 March 2009, 09:58 | #6 |
68k
Join Date: Sep 2005
Location: Somewhere
Posts: 828
|
Hi
There you can find resourced version of this effect ( thx StingRay for correction ) ( Look into Prestige cracktros ) http://cyberpingui.free.fr/rsources.htm. Regards Last edited by Asman; 26 March 2009 at 10:53. |
26 March 2009, 10:14 | #7 |
move.l #$c0ff33,throat
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
|
He asked for commented sources (i.e. comments for the effect code) though, the one on cyberpingui's site is a resourced version.
|
26 March 2009, 10:53 | #8 |
68k
Join Date: Sep 2005
Location: Somewhere
Posts: 828
|
You're right. Thx for correction.
|
27 March 2009, 16:54 | #9 | |
Registered User
Join Date: Mar 2009
Location: moon
Posts: 373
|
Quote:
|
|
31 March 2009, 18:11 | #10 |
Banned
Join Date: Jan 2009
Location: U.K.
Posts: 93
|
Hi folks.
Here is the basic source code for same effect. It was written by Paul Rene over at the Blitz Basic web site. The code is for Blitz Plus so just download the PC demo first then load the code in below... Looks really nice and shouldn't be too difficult to convert to the Amiga. See ya, Kev G. ; ; Kumppa v1.0 ; ; Ported by Paul Rene Jørgensen, paulrene@pilen33.org ; Global screenWidth, screenHeight Global middleX, middleY Global stateX, stateY Global rotSizeX, rotSizeY Global rx, ry Dim xRotations(1) Dim xRotTable(1) Dim yRotations(1) Dim yRotTable(1) Dim chks(1) Dim rotateX(1) Dim rotatey(1) screenWidth = 800 screenHeight = 600 middleX = screenWidth/2 middleY = screenHeight/2 Graphics screenWidth,screenHeight,32,2 initializeRotations(0.05,0.05) While Not KeyHit(1) SetBuffer BackBuffer() r=Sin(a+0)*255 g=Sin(a+90)*255 b=Sin(a+180)*255 Color r,g,b If(Rand(0,10)<2) Then Color 0,0,0 a=a+4 : If a>=360 Then a=a-360 If Not KeyDown(15) Line middleX,middleY,middleX+Cos(a)*4,middleY+Sin(a)*4 EndIf While KeyDown(57) : Delay 25 : Wend rotate() CopyRect 0,0,screenWidth,screenHeight,0,0,FrontBuffer(),BackBuffer() ;VWait Flip Wend Function rotate() rx=xRotTable(stateX+1)-xRotTable(stateX) ry=yRotTable(stateY+1)-yRotTable(stateY) For x=0 To rx If x<>0 Then rotateX(x)=middleX-1-xRotations(xRotTable(stateX+1)-x) Else rotateX(x)=0 Next For x=0 To rx If x=rx Then rotateX(x+rx+1)=screenWidth-1 Else rotateX(x+rx+1)=middleX+xRotations(xRotTable(stateX)+x) Next For y=0 To ry If y<>0 Then rotateY(y)=middleY-1-yRotations(yRotTable(stateY+1)-y) Else rotateY(y)=0 Next For y=0 To ry If y=ry Then rotateY(y+ry+1)=screenHeight-1 Else rotateY(y+ry+1)=middleY+yRotations(yRotTable(stateY)+y) Next If rx>ry Then x=rx Else x=ry For dy=0 To ((x+1)*2)-1 For dx=0 To ((x+1)*2)-1 If rx>ry Then y=ry-rx Else y=0 If ((dy+y)>=0 And dy<((ry+1)*2) And dx<((rx+1)*2)) If ((dy+y+dx)<=(ry+rx) And (dy+y-dx)<=(ry-rx)) palaRotate((rx*2)+1-dx,dy+y) palaRotate(dx,(ry*2)+1-dy-y) EndIf EndIf If ry>rx Then y=rx-ry Else y=0 If ((dy+y)>=0 And dx<((ry+1)*2) And dy<((rx+1)*2)) If ((dy+y+dx)<=(ry+rx) And (dx-dy-y)>=(ry-rx)) palaRotate(dy+y,dx) palaRotate((rx*2)+1-dy-y,(ry*2)+1-dx) EndIf EndIf Next Next stateX=stateX+1 If stateX=rotSizeX Then stateX=0 stateY=stateY+1 If stateY=rotSizeY Then stateY=0 End Function Function palaRotate(x,y) SetBuffer FrontBuffer() ax=rotateX(x) ay=rotateY(y) bx=rotateX(x+1)+2 by=rotateY(y+1)+2 cx=rotateX(x)-(y-ry)+x-rx cy=rotateY(y)+(x-rx)+y-ry If cx<0 ax=ax-cx cx=0 EndIf If cy<0 ay=ay-cy cy=0 EndIf If (cx+bx-ax)>screenWidth Then bx=ax-cx+screenWidth If (cy+by-ay)>screenHeight Then by=ay-cy+screenHeight If (ax<bx And ay<by) CopyRect ax,ay,bx-ax,by-ay,cx,cy,BackBuffer(),FrontBuffer() EndIf End Function Function initializeRotations(xSpeed#, ySpeed#) a=0:b=0:c=0:f=0:g=0:j=0:k=0:l=0:maxi=0 m#=0.0m#=0.0k#=0.0:d#=0.0:ix#=0.0:iy#=0.0 rotSizeX = (2.0/xSpeed#)+1 ix = (Float middleX+1.0) / Float rotSizeX rotSizeY = (2.0/ySpeed#)+1 iy = (Float middleY+1.0) / Float rotSizeY Dim xRotations(middleX+2) Dim xRotTable(rotSizeX+1) Dim yRotations(middleY+2) Dim yRotTable(rotSizeY+1) m = middleX If(middleY>middleX) Then m = middleY Dim chks(m) maxi = 0 c = 0 d = 0 g = 0 For a=0 To (middleX-1) chks(a) = True Next For a=0 To (rotSizeX-1) xRotTable(a)=c f=Int (d+ix#)-g g=g+f If g>middleX f=f-(g-middleX) g=middleX EndIf For b=0 To (f-1) m=0 For j=0 To (middleX-1) If chks(j)=True om=0 ok=1 l=0 While ((j+l)<middleX And (om+12*ok)>m) If (j-l)>=0 If chks(j-l) om=om+ok EndIf ElseIf chks(l-j) om=om+ok EndIf If chks(j+l) Then om=om+ok ok=ok/1.5 l=l+1 Wend If om>=m k=j m=om EndIf EndIf Next chks(k)=False l=c While (l>=xRotTable(a)) If l<>xRotTable(a) Then xRotations(l)=xRotations(l-1) If (k>xRotations(l) Or l=xRotTable(a)) xRotations(l)=k c=c+1 l=xRotTable(a) EndIf l=l-1 Wend Next d=d+ix If maxi<(c-xRotTable(a)) Then maxi=c-xRotTable(a) Next xRotTable(a)=c Dim rotateX((maxi+2)*2) maxi=0 c=0 d=0 g=0 For a=0 To (middleY-1) chks(a) = True Next For a=0 To (rotSizeY-1) yRotTable(a)=c f=(d+iy)-g g=g+f If g>middleY f=f-(g-middleY) g=middleY EndIf For b=0 To (f-1) m=0 For j=0 To (middleY-1) If chks(j) Then om=0 ok=1 l=0 While ((j+l)<middleY And (om+12*ok)>m) If (j-l)>=0 If chks(j-l) om=om+ok EndIf ElseIf chks(l-j) om=om+ok EndIf If chks(j+l) Then om=om+ok ok=ok/1.5 l=l+1 Wend If om>=m k=j m=om EndIf EndIf Next chks(k)=False l=c While (l>=yRotTable(a)) If l<>yRotTable(a) Then yRotations(l)=yRotations(l-1) If (k>yRotations(l) Or l=yRotTable(a)) yRotations(l)=k c=c+1 l=yRotTable(a) EndIf l=l-1 Wend Next d=d+iy If maxi<(c-yRotTable(a)) Then maxi=c-yRotTable(a) Next yRotTable(a)=c Dim rotateY((maxi+2)*2) Dim chks(1) ; Free mem End Function |
02 April 2009, 02:07 | #11 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
|
It's quite uninteresting to convert a derivative back to the original platform. But it was a while since I saw While/Wend, thanks for that
"Blitter feedback"? Then a right to left scroller is blitter feedback. That doesn't mean it's a nice idea though |
02 April 2009, 10:28 | #12 |
move.l #$c0ff33,throat
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
|
|
02 April 2009, 16:39 | #13 |
Registered User
Join Date: Jun 2008
Location: somewhere else
Posts: 511
|
If i remember well this was basically a grid of squares and each of them was scrolled individually by the blitter (in x/y) and copied into the back buffer, then at regular interval a pattern was drawn into that buffer. The whole process was randomly moved in x/y to give that fractals look and moved the opposite way with the copper to stabilize it on the screen.
Nothing fancy but it was a rather creative piece of code back then. |
02 April 2009, 16:41 | #14 |
Moderator
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
|
No, YOU said feedback You explain what you mean with Blitter Feedback!
I still say this is what effects is all about. New, maybe simple, maybe complex ideas... but it takes a coder with imagination to invent them, and a strict coder to make them perfect. Here's the one by Dweezil: http://bitworld.bitfellas.org/demo.php?id=9813 The Shining one was good, but they ruined it a little by making it 1bpl, so it looked like a fast RotPlot with 5 shadow bitplanes... Last edited by Photon; 02 April 2009 at 22:47. |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Making a Cracktro-Like Text Scrolling Effect | mattbarton.exe | Amiga scene | 12 | 31 May 2022 21:12 |
twister effect | Coagulus | Coders. General | 91 | 14 March 2017 20:45 |
Overlay effect | MrX_Cuci | request.UAE Wishlist | 15 | 30 June 2010 17:35 |
Another scanlines effect | Leandro Jardim | request.UAE Wishlist | 6 | 27 June 2010 19:37 |
Chessboard effect | Six | Coders. General | 11 | 09 January 2007 15:45 |
|
|