Discord
Login
Community
DARK THEME

How does 3D projection work?

Found this cute little explanation on pico-8. Not as good as @that_name_explains_it_better , but fun to watch :)

Link

Live Long And Tinker

Thanks for sharing!

I like it! However, I think that this 3d projection method is quite interesting (I might even give it a try, perhaps!) but is different from most of the 3d projection methods I know.

The traditional 3d projection method is just (for xyz points, and a field of view of FOV)

FOV*x/z
FOV*y/z

And this method works if you are rendering a 3d space. This method has some similarities (divide x values by distance, then scale up by FOV) but the main difference is that it stores a 3d space.

Due to this, this method seems similar to raycasting - although obviously, there is no 'ray' or 'casting'. That's because this uses the method of rendering a 2d map onto a 3d space - meaning it only stores a 2d space. However, it still incorporates elements of the prior method inside it (again, divide x values by distance then scale up by FOV).

Very interesting, thanks for sharing, @tinker_guy_who_shared_it

@tinkersmith

Success! After about half an hour of work, I 'tinkered' up a very rough program that works using exactly this method!

:embed https://microstudio.io/this_name_is_taken/3dtinkerprojection/2KKR4ZTR/

Has a little more work to go before I release it though.

Uuuuh, looking good :) @that_name_is_multidimensional

LOL, had a suspicion you might have a go at it. Yes, is 2d flat map data only, kind of like the list based raycaster. But again, looking so cool :)

Tanks for your tip!

I believe you'll find this tutorial useful as well:

https://lodev.org/cgtutor/raycasting.html

Post a reply

Progress

Status

Preview
Cancel
Post
Validate your e-mail address to participate in the community