Misc details

Published May 07, 2010
Advertisement
Fixed up some small details.

The tree is made up of two vertical planes + some horizontal planes. The lighting became all strange due to the vertical planes and their normals. I added a hack/fix in the vertex shader so that if it's a vertical plane, the normal will face up.

Also added an attrib map from L3DT. For now I only use this in the fragment shader of the terrain to deside the gloss level at each pixel. The attrib map consist of a color code for each ground-terrain type, so that with a simple color value I know whether it's sand, rock, cliff, grass, etc. I can probably find uses for this map on the C++ side too, to set correct foot-on-ground sounds, particle effects by shots/feet and to spawn trees, grass and rocks randomly.

Previous Entry Shadow mapping
0 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Advertisement