Tuesday, June 28, 2011

Mesh re-projection of a Tree

I did this screenshot recently. It shows how original geometry can be compressed and still retain most of its complexity in the textures. The subject in this case is a tree:


As usual you can click on the image to get a higher resolution version.

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.


Thursday, June 23, 2011

Mounts and Light

Just a render of a small mount:


I added some fog to this image. Eventually I will be generating how light bounces off the particles in the air. If you  noticed, you can see the top of a mountain more clearly than the bottom. This is because the air at the top is thinner and light gets easier to you.

Hopefully I can have the same principle inside architecture so there will be a nice ambient feel to interior spaces too.

Friday, June 17, 2011

Mesh re-projection, a screenshot

This screenshot illustrates another key step in the world generation workflow:


As you can see I threw in the silhouette of a gentleman so proportions can be better appreciated.

The world geometry is initially generated in very high detail. I want this to run on low-end devices, so using this geometry in the client is out of the question. The high detail geometry is simplified until a certain thereshold of polygons per volume is met. For this I use simplification based on Quadratic Error Metrics, but a flavor of my own. I tested several of the mesh optimization codes out there, not one could simplify the huge meshes I was generating fast enough. I plan to cover that side of the story in a future post.

Then the high resolution geometry is projected onto the low resolution geometry, so a lot of the detail is preserved in form of textures. I will cover this method in the future too, but it is very similar to the one described in GPU Gems 3, Chapter 22.

As as result, an entire world scene can be rendered with a very small number of polygons, which will come very handy I'm sure.

Friday, June 10, 2011

2000 Sticks

Did you ever wonder how 2000 sticks would look like if they were arranged into some sort of cubic space? I just found out:
You can click on the image to get a higher resolution.

I was using this as a dataset for testing some optimization in the segment field functions, the same I use for generating tree branches and trunks. The optimization like many other turned out to be a dead end, but I don't regret it. I got my box of sticks.