Author Topic: [Axe] Plane deformations are fun  (Read 26107 times)

0 Members and 1 Guest are viewing this topic.

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #30 on: January 29, 2014, 01:30:07 am »
Glad to hear that it helped. This would be a great effect to have for a demoscene program. Speaking of demoscene, you should have a magnifying lens effect, as was common in demos for older systems. Also, if you want the GIFs to be smoother, crank up the framerate setting in Wabbitemu.
We're not talking about the same thing here. Lens effect can't be achieved with a single formula for U and V, it needs a whole algorithm.

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #31 on: January 29, 2014, 10:15:43 am »
Bump,

Okay so I tried my best to optimize PLDEFORM like hell, and I managed to make it exactly 1023 bytes ! :w00t: Since I had to drop #ExprOn, it remains 6 FPS, but I tried and at 15 MHz it's 14.30 FPS :D

So I've made an actual demo out of it, named it Illogical (guess why ;D) and posted it on pouet.net and ticalc.org.While it's waiting for approval, I provide a screenshot of the 15 MHz version + download link for binaries and source ! :D

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: [Axe] Plane deformations are fun
« Reply #32 on: January 29, 2014, 10:16:50 am »
That is awesome fast! (but yeah, 15MHZ, make it faaaaaaster >:D )

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #33 on: January 29, 2014, 10:18:05 am »
I really tried everything to make it fast, I don't think it's possible that it'll ever go faster half of an FPS :P

EDIT : here you go :D http://www.pouet.net/prod.php?which=62454
« Last Edit: January 29, 2014, 10:19:45 am by Matrefeytontias »

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: [Axe] Plane deformations are fun
« Reply #34 on: January 29, 2014, 10:27:39 am »
Aaand here's what I did, inspired from your program.

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #35 on: January 29, 2014, 10:29:31 am »
Haha nice, glad to see I inspired people ;D

Offline XiiDraco

  • LV7 Elite (Next: 700)
  • *******
  • Posts: 513
  • Rating: +32/-5
  • Forget the numbers, just call me, Recreation.
    • View Profile
    • Black-Lark Games
Re: [Axe] Plane deformations are fun
« Reply #36 on: January 29, 2014, 10:30:50 am »
Woa. Eiyeron. That's pretty cool!

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
« Last Edit: January 29, 2014, 10:59:50 am by Eiyeron »

Offline fb39ca4

  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1749
  • Rating: +60/-3
    • View Profile
Re: [Axe] Plane deformations are fun
« Reply #38 on: January 29, 2014, 11:19:27 am »
We're not talking about the same thing here. Lens effect can't be achieved with a single formula for U and V, it needs a whole algorithm.
Here's something I put together quickly that produces the lens effect as a function of UV.
https://www.shadertoy.com/view/Xsj3RV

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #39 on: January 29, 2014, 11:21:22 am »
Okay good, now give me the separate equations for U and V and I'll try to put it in my plane deformer.

Offline Sorunome

  • Fox Fox Fox Fox Fox Fox Fox!
  • Support Staff
  • LV13 Extreme Addict (Next: 9001)
  • *************
  • Posts: 7920
  • Rating: +374/-13
  • Derpy Hooves
    • View Profile
    • My website! (You might lose the game)
Re: [Axe] Plane deformations are fun
« Reply #40 on: January 29, 2014, 11:24:44 am »
bleh, my chrome doesn't support webgl :(

THE GAME
Also, check out my website
If OmnomIRC is screwed up, blame me!
Click here to give me an internet!

Offline fb39ca4

  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1749
  • Rating: +60/-3
    • View Profile
Re: [Axe] Plane deformations are fun
« Reply #41 on: January 29, 2014, 11:25:28 am »
After transforming the coordinates so that the origin is at the center of the screen and r is the distance from the origin, x' = 0.5 * x * (r^2 + r) and y' = 0.5 * y * (r^2 + r) for all points where r < 0.5. Otherwise, the coordinates are unchanged.

Also, a suggestion for the demo: You should generate the LUT for the next scene in the background while the current one runs, so that there isn't a pause between scenes. After each frame is drawn, generate one line of the LUT.
« Last Edit: January 29, 2014, 11:32:04 am by fb39ca4 »

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #42 on: January 29, 2014, 11:30:34 am »
Apparently I'm getting overflows. Lemme try harder before seeking help if it doesn't work.

Offline Eiyeron

  • Urist McEiyolobster
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1430
  • Rating: +130/-10
  • (-_(//));
    • View Profile
    • Rétro-Actif : Rétro/Prog/Blog
Re: [Axe] Plane deformations are fun
« Reply #43 on: January 29, 2014, 11:32:05 am »
Code: [Select]
#ifdef TELEPORT_EFFECT
u = a;
v = 1./(r + sin(r + time));
#endif
TELEPORTATION TIME! \o/

Offline Matrefeytontias

  • Axe roxxor (kinda)
  • LV10 31337 u53r (Next: 2000)
  • **********
  • Posts: 1982
  • Rating: +310/-12
  • Axe roxxor
    • View Profile
    • RMV Pixel Engineers
Re: [Axe] Plane deformations are fun
« Reply #44 on: January 30, 2014, 02:39:49 pm »
Bump,

So my demo made it on Pouet ! :w00t: https://www.pouet.net/prod.php?which=62454

And ticalc too ! :D http://www.ticalc.org/archives/files/fileinfo/458/45819.html

Let's spam the staff with mails saying to feature it :evillaugh:

Final gif :

« Last Edit: January 30, 2014, 02:40:13 pm by Matrefeytontias »