Since the start of the project, I knew the gas giant of Giant’s Deep would be a significant tech art challenge. Hidden under a thick layer of clouds lies an ocean planet, and I knew I wouldn’t be happy throwing some scrolling normal maps on a sphere and calling it a day. As such, I decided I wanted an ocean with real waves.
The first big stumbling block to achieving this was having the polygons to turn into waves. We’d need to have it be a pretty high-resolution mesh, as you can jump down into the ocean in person, which makes the small waves just as important as the big ones. But we couldn’t have that detail everywhere, as that would choke things to a crawl pretty quickly. So we needed a giant sphere that gave us detail where we needed it, and faded it out where we didn’t.
Thinking about the problem, I broke it down into an idea of having patches of different resolution stitched together into a sphere. A quad-sphere seemed the best solution, as that would be the easiest topology to work with. Using Philip Nowell’s excellent cube-to-sphere mapping equations meant that I could just treat it like a cube, and then have the GPU do the work of warping it into a nice rounded shape, like so: