5
\$\begingroup\$

The open source game Glest has models that feel detached from the ground that they sit on because of the hard edges. In real life, grass is not flat!

What are the options and recommendations for breaking up the hard edges where the meshes of the models meet the terrain? How do other games do it? What are the options on a sliding scale of rendering performance and widespread GPU support?

A screenshot from glest

\$\endgroup\$

3 Answers 3

5
\$\begingroup\$

I downloaded and ran the game from http://www.glest.org, and the "feet not on the ground" issue comes from lack of shadows and other visual cues that help you get the perspective right.

In the screenshot you posted, shadows seem to be turned off. Turn them on to get a better effect. Even when using the shadows Glest provides, the shadows are pretty weak. But turning them on does help reduce the floating characters effect.

Take a look at the screenshot below I took from Glest. The models fail to visually blend into their terrain because the textures don't visually blend between object and ground, nor are there any shadows.

alt text

Now take a look at this picture. This is the same scene, but I did a quick photoshop job to add shadows and a few other changes by hand. The characters and some objects (I didn't do everything) have a dark shadow blob under them. The shadows aren't even real shadows (shaped like the object), but simply darker "blobs" at the object's base. They are also overly dark, but on purpose.

alt text

In addition to the shadow blobs, I darkened the bases of the objects (base of rocks, base of buildings, character feet) so that they better blend into the shadow "blob" under their feet.

So my advice is to add stronger shadows under objects, even if with blobs to fake a shadow. And also darken the textures of objects where they contact the ground. These are things a nice high end engine could take care of for you with the lighting model, but there are ways to still get the effect.

\$\endgroup\$
9
\$\begingroup\$

I think that the problem of objects which look like flying is realy not about hard edges but it is problem of "absence of shadows".

For shadows google for "shadow mapping" or "shadow volumes".

If you really dont want hard edges. Use alpha transparency for vertices near ground (it could be easy). But then you have to sort objects which you are rendering in distance from camera. But it will not produce anything nice i think. In fact i'm pretty sure that there is no way how to get rid of hard edges in computer grapgics.

\$\endgroup\$
3
  • \$\begingroup\$ What about soft-particles. Those don't have hard edges. makingartstudios.com/images/research/fullsize/… \$\endgroup\$ Dec 21, 2010 at 23:58
  • \$\begingroup\$ Well this is very nice. Do you know how it work? Or have some related papers? I'm very interested in this topic. Doesnt it just fade out fragments alpha when it is near to object? \$\endgroup\$
    – Notabene
    Dec 22, 2010 at 0:28
  • 1
    \$\begingroup\$ I think shadows and hard edges are two separate issues. Simply adding a shadow "blob" under the character's location would greatly improve the appearance of their feet being on the ground. Also, the texture for the feet and legs should subtly get darker so that they blend in a bit into the darker area the shadow creates. \$\endgroup\$
    – Tim Holt
    Dec 22, 2010 at 18:04
3
\$\begingroup\$

You can render grass. There are a couple of widespread techniques for this that I've seen; one uses lots of little billboards, placed in a clever fashion. The other works more like a static particle system, where each blade or bunch of grass is a particle. They end up generating much the same geometry, if I recall correctly.

\$\endgroup\$
1
  • \$\begingroup\$ +1 also transparent mapping on bigger simpler polygons can usually achieve the illusion of a lot of detail. In general, use good 3D artists and trickery, not technology and brute force ^^ \$\endgroup\$ Dec 21, 2010 at 19:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .