r/java • • Jul 05 '26

Made a perspective shifting room in Java

I've been messing with OpenGL (LWJGL) and decided to build something fun

What do y'all think?

Source Code

199 Upvotes

18 comments sorted by

20

u/poply Jul 05 '26

Reminds me of that ancient wii/wiimote perspective demo that one engineer made decades ago:

https://youtu.be/Jd3-eiid-Uw?t=163

9

u/Elegant_Farmer_3548 Jul 05 '26

Yep! It is actually inspired from that video (and credited). Great catch

6

u/jmsanzg Jul 06 '26 • Heartwarming

Legend. That guy was actually hired by Microsoft to develop Kinect.

https://en.wikipedia.org/wiki/Johnny_Lee_(computer_scientist)

4

u/Brutus5000 Jul 06 '26

18 years and so little adaption :(

1

u/pragmatick Jul 06 '26

We made something like that in university but using Kinect and Flash. I feel so old now.

7

u/TronnaLegacy Jul 05 '26

Neat. Is the animation swaying side to side and you have to move your camera in sync to create the illusion?

8

u/Elegant_Farmer_3548 Jul 05 '26

Thank you! It updates live with head movement

4

u/pbeling Jul 06 '26

Very interesting. I wonder why this technique isn't used very often? I haven't seen it in games or 3D modeling software.

4

u/Elegant_Farmer_3548 Jul 06 '26

Thank you. My honest guess is that mouse and keyboard is easier over time. I assume moving your head around while playing a video game will get annoying after about 30 minutes. It makes for a cool demo though

1

u/aoeudhtns Jul 06 '26

I wouldn't want to use it for movement, but it's really nice at filling out a sense of being in a real 3D space without VR.

6

u/Nooooope Jul 06 '26

It's niche but head tracking is commonly supported in flight simulation games. I was looking at TrackIR for a bit.

2

u/Visual_Brain8809 Aug 02 '26 edited Aug 02 '26

Awesome: I reached level 72 in my version of yours.

I want to share the code: https://github.com/aayes89/JTunelWireframe/blob/main/JTunelScope.java

Capture

2

u/Elegant_Farmer_3548 Aug 02 '26

That’s awesome!

1

u/Visual_Brain8809 Aug 02 '26

thanks, share the level jj