Trying to map a 2d array into a disk

No Mechaenetia make me sad, so i decided to figure out. How hard can it be to map a 2d array into a Disk. Answer: Very hard

Anyways so to to make this i had to rewatch a video on making minetest into a torus some times and mix some values and figure out some constants over and over again. but i think i have a ok method now.
Dont mind that its circles(i am too lazy to connect squares)

you can find this project at this github url, though i dont recommend using any of this code as it sucks and the math is barely right

2 Likes

some more progress later and ive made this


the weird chunks is because i just rotate a square texture without moving the vertexes to go into each other

i have 3 things that i can do next.

  1. fix the math(its duct tape together, and i dont know math)
  2. fix the vertexes together(dont wanna, and never done shaders before)
  3. make a donut(oh hell naw)

basically im to lazy to improve this anymore

2 Likes