P-152: Virtual World Concept Update 167: Planet-sized Terrain: Part 46
by PhoenixGames on Sep.04, 2016, under Astral Realms, P-0, Software and Games, Spiritus Astrum
The idea that I had to correct the offset on the Z-axis didn’t seem to be working out well, so I decided to try to convert the coordinate system that I am using into spherical coordinates.
Once I have done this, the plan is to use Rodrigues’ rotation formula to rotate, instead of translate, the nodes. IE, instead of moving the nodes back towards the origin (in a linear fashion) as the player moves, I would instead rotate the nodes back along the radius of the planet. I can then convert the nodes back to cartesian coordinates, and this should solve the problem.
This process has been going well, and I think I am fairly close to being able to implement this, but I am not sure if it will actually work.
The first of the below images show my attempts to add an offset to the z-axis of the terrain. I made some progress with this, but it is quite a messy solution, and doesn’t appear to work as well the further the player travels from the origin (in world space).
These images show my attempts to convert the cartesian node positions to spherical.