Tunel Effect - First Attempt
So finally I did my own tunel effect and I’m quite happy about it. It’s simple, it’s not perfect, but it’s mine :)
So lets back to thinking about tunel. What do we acctually need?
- Texture - that we have from roto zoom effect (x xor y)*
- Scaling from the center to the edges *
Remember how to scale texture? Just draw each pixel as many times as much you want to scale. So if we want to have big texture at the edges of scene, then we need to divide X coordinate by distance from the center.
Let’s do some psuedo code:
And now, presentation: