You can get Voxel Farm now. For more information click here.

Sunday, June 26, 2011

June Snow

It was a long weekend in Quebec. The snow is long gone, but it rained a lot. I got some time to improve the placement of snow textures in the virtual world.

As I have it, snow appears in a scene for one of two reasons: there is some volume accumulated on the ground, or a layer of snow covers other features like rocks.

When it accumulates it becomes a feature of its own. It usually forms waves and dunes. I found it can be recreated as a 3D volume layer using some form of multi-fractal ridged noise. To this volume I apply a snow texture.

When it appears on other features like rocks and boulders, I model it as a set of additional texture layers for the rock or boulder material. This means that every material needs to know how it will look when covered by snow. I will post about the material system in the future. As you will see, adding snow takes little effort.

Here are some screenshots showing the latest results I've got:




The three screenshots were taken out of the same mountains.

I found not so hard to re-create areas that were completely covered by snow. The tricky part was the transition zones, where snow gradually disappears and the ground starts to show again. The last screenshot shows a transition area. I still need to work on them.


12 comments:

  1. Can I just say, looks absolutely awesome!
    I can't wait for... whatever it is... that pops out at the end of this :-D

    ReplyDelete
  2. These are great mountains, they really look like they've been produced by the churning of great tectonic forces and erosion.

    It seems to me that as the climate gets warmer (ie further down on the mountain) the snow should tolerate smaller and smaller inclines. I'm guessing you're doing something similar to that in the transition zones?

    Also the grass should probably lose it's saturation and be less tolerant of inclines as it gets colder/higher up.

    ReplyDelete
  3. Thanks Simon. You are correct, transition zones appear as a combination of height and slope. You can think of it as a probability function. Below certain height it is 100% sure there is no snow. Then for certain height range, snow probability will depend on both height and slope. I also threw in a Perlin noise. Even if the height and slope are right, it is not sure there will be snow. And then, above the freeze height point it is just the slope.

    ReplyDelete
  4. I just want to say that this whole project is just incredible.

    ReplyDelete
  5. Two things. Firstly, this is an incredible project and could wind you up being very rich :)

    Also, a technical note: What size voxels do you use, and how far are they pushed into each other?

    ReplyDelete
  6. @Anonymous: I'm glad you think like that. I'm doing this only for the money :)

    Voxel size is actually adaptive, some materials can do down to one cubic inch. Space division follows material type and also the complexity of the scene. I'm not sure what you mean by pushing voxels into each other.

    ReplyDelete
  7. Thanks for that. What I meant was that with Dual Contouring, the vertice output is based on where one voxel is inside another? So with every four voxels on an edge, some are crossing the edge, right, which means they are pushed into each other? I think!

    ReplyDelete
  8. @Anonymous: In dual contouring a vertex is output if the surface crosses anywhere inside the voxel. If the surface crosses one edge, the four neighbor voxels have a crossing, which means a patch of surface can be output by building a quad with the vertices inside those four voxels. But for a regular grid voxels are never inside other voxels, or pushed into other voxels...

    ReplyDelete
  9. hey
    I found your projext by way of shamus mentioning you on your blog, i finally decided to check it out, and i am so happy i did. This is utterly mindblowing. It looks incredible, and it mentioned in the article of edge youre hoping to turn it into a dwarf fortressy style city sim.I'm fairly certain i've stumbled into heaven. keep up the amazing work and know you've made an instant fan

    ReplyDelete
  10. Thanks Fuzzy. Note I'm still not sure what will be the outcome of this. And if I do something like Dwarf Fortress, it may be closer to its adventurer mode.

    ReplyDelete
  11. In the upper right corner of your second image, there looks like there is a piece of land floating in the air. Is it just a bug, or a display issue or something?

    ReplyDelete
  12. @Anonymous: It is floating land. The algorithms I use for rocky formations know nothing about gravity. I will filter these oddities out later in the process.

    ReplyDelete

There was an error in this gadget