infinite 2011-07-11 19-37-53-44formseq-2010-11-16-13-58-15rampsnightvoxracer-2013-03-13-22-23-48-61vxislan4ruinsexperiment 2012-01-07 23-13-14-55avseq-nov 2011-12-24 19-46-42-16ruins8sir9sir-oct5NullSetAV-2013-03-07-17-32-38-59voxracer-2013-03-13-22-26-02-23ruins13infinite 2011-07-11 19-39-28-02

Voxelwrapped terrain images

I’ve been extending the Voxel wrapping framework from the previous post or two into a more fully fledged procedural terrain system. I wanted to get a reasonable sense of scale and distance, but I didn’t want to cripple the framework with too much crazy LOD code. Inititally I did implement a LOD scheme , where the chunked voxelcubes that make up the terrain stepped to covering 2x the volume at a specific distance (lowering the resolution by half). This inevitably led to some degree of popping, where the geometry suddenly realigns to a finer mesh as you approach. What I realised is that on a traditional 2d heightmap terrain this sort of LOD can work well, since essentially the popping only happens vertically (ie a hill becomes slightly flatter or angular as it gets further away). On a full 3d terrain the popping happens in all dimensions. Its much more noticeable to see a floating island suddenly deform at all its edges.

vxislan8

In the end I decided to use a brute force mesh and implement some fogging and a sensible skybox to merge the distant polys into the horizon. This works well enough and maintains the fidelty of any floaty rock formations. As I was working on this I checked a number of other terrain engines in open world games and realised that, in many cases, low poly terrain can easily be given more scale and detail with simple grass scattering. Ive now implemented this within the procedural generation routine. There are some issues specific to a full 3d terrain as grass is basically projected from the sky onto the generated terrain mesh. So a floating island will stop grass growing beneath it at the moment. However it works well enough for now and certainly improves the sense of scale and variation.

vxislan3

The grass meshes use a shader I wrote that perturbes their upper vertices with a sine function to imitate wind. Each vertex point is sampled as an offset, so they dont all wave in unison, but you can control strength and ocscillation speed. Ultimately Id quite like to get the mesh to part around the player, but its not important for now. Also, to speed up rendering, once they grass meshes are located I combine them all into a single mesh for improved drawcalls. Its a similar method to how I will be doing scenery (and how it worked in the earlier prototypes) but there are lots more grass meshes than you would have trees. Anyway the existing procedural texturing shaders are still wroking fine in the terrain, and I’ve been experimenting with a ange of colors and gradient effects. As usual there are more images on my flickr stream.

vxislan6

vxislan2


3 responses so far, want to say something?

  1. Rob James says:

    I’m loving the stuff you’re getting here. especially the third one down (looks suitably shadow of the collosus-esque)

    sorry for the pretty pointless comment, but I’ll be checking back here often :D

    cheers!

  2. justin says:

    dude! that’s beautiful! hey, i come from The Witness. let me ask you… what do you use? where do you model and where do you program? i am a begging animator and programmer (when i say beginner i mean 6 months in my first high school classes) so yeah, i don’t know anything but i want to do a real game already. what programs do i need and what do you call this, so that i can look for tutorials. is this stuff what they call “real-time graphics”? thanks for the help and thank you for your time! : )

  3. James says:

    You haven’t been associating with that Rossignol character, I hope…he’s trouble!

    Good stuff. Could you make the terrain form into giant plants/trees? If so, please do that.

Leave a Reply