Advertisement

Loopix trees look odd in Blender...

Started by October 31, 2007 06:28 PM
13 comments, last by ZealousEngine 17 years, 2 months ago
If anyone has some experience with Blender, would you mind taking a look at this test tree? Its a free test tree form the Loopix tree collection (a really great set). http://www.loopix-project.com/downloads/test_tree.zip For some reason when I import it into Blender (in any of the formats), the normals on each 'leaf quad' seem to allign perpendicular with the plane. The problem is, if you have a backface thats facing towards the light, it will NOT be lit (because the normals are pointing in the opposite direction). It looks really bad. So does anyone know how to fix the normals for these trees in Blender? Perhaps some way to get the normals on the quads to allign parallel with the plane (like you do for grass quads)? Or some way to generate normals for the backfaces maybe? Just something to make it look better than this! Thanks in advance!
Heres a picture showing what im talking about...

http://img30553.pictiger.com/images/12931797/

Heres what the tree looks like (even after recalculating the normals in Blender). This shot was taken at mid day (sun directly above the tree). Like I said, the normals are facing perpendicular to each quad, and there are only normals for the front face (backface lighting is determined by the frontface).

How can I fix these trees :( ?
Advertisement
I emailed Loopix directly on this issue, and he said it sounds like a vertex welding issue? He said..

Quote: Try to find a "weld" "weld all vertices" or "weld model" fuction.


Anyone know how to do that in blender?
The way it looks to me is that the tree is modeled using as few planes as possible and is made to render 2-sided. Now, what you're describing is actually normal (no pun intended). Only one normal exist per plane and as few planes are used as possible needing to be rendered 2-sded (meaning render on either side despite which side has the normal pointing). Because of this, any lighting that calculates the lighting using normals will not light the non-normal side.
A common solution to this is self-illumination on the leaf texture, that way it is always the same brightness no matter which side the normal is on. However, you can experiment with other methods, but just so you know, this isn't a problem with the tree. Its something we all have to deal with in game models.
-------------------------Only a fool claims himself an expert
Youre right, but I know these specific trees arent supposed to have this problem. In the past I was able to get them lookign great in my old engine (using 3ds max). The problem now is just how to 'weld' the vertices in blender. According to Loopix this should fix the problem im having.
Quote: Original post by ZealousEngine
Youre right, but I know these specific trees arent supposed to have this problem. In the past I was able to get them lookign great in my old engine (using 3ds max). The problem now is just how to 'weld' the vertices in blender. According to Loopix this should fix the problem im having.

Is your engine using stencil shadows? If so then you can not have the leaves casting shadows (at least the usual stencil shadow implementation has this limitation). However other than that i fail to see how welding some verts will fix the lighting, but that may just be me.
However i don't know how to weld verts in blender, so hopefully you can get some more help in that area from a blender user.
-------------------------Only a fool claims himself an expert
Advertisement
Well I found out alt-m brings up the 'combine' menu, but it does no good, there is only one vert per corner on each quad. There is simply nothing to weld.

Does anyone have another modeling app like max or maya? can you try importing that test tree and tell me if the normals on the quad are messed up? Maybe this whole problem is just blenders import routine..
Quote: Original post by ZealousEngine
Well I found out alt-m brings up the 'combine' menu, but it does no good, there is only one vert per corner on each quad. There is simply nothing to weld.

Does anyone have another modeling app like max or maya? can you try importing that test tree and tell me if the normals on the quad are messed up? Maybe this whole problem is just blenders import routine..

Well, not to sound like a broken record, but if there is truly only 1 vert per corner, then the tree is in fact modeled out of planes as suggested above. And because of this, if your engine uses the normal to calculate lighting, the leaves will not light correctly if they're being rendered 2-sided with the normal pointing away.
Meaning, some of the quads will light correctly (the ones with the normal facing the light) and some of them will not (the ones with the normal opposite of the lighting direction).
-------------------------Only a fool claims himself an expert
The way to have a normal on both sides of the face is to duplicate the faces, and press flip normals with the new duplicates selected. If you are drawing double sided an duplicating this of course will be a disaster.
Quote: Original post by hogarth
The way to have a normal on both sides of the face is to duplicate the faces, and press flip normals with the new duplicates selected. If you are drawing double sided an duplicating this of course will be a disaster.

There are work arounds, but yeah, not much you can do if you only have one normal, which can only point in one direction at a time.
-------------------------Only a fool claims himself an expert

This topic is closed to new replies.

Advertisement