Page 1 of 1

2 Sided Materials ?

Posted: Fri Jul 04, 2008 6:42 pm
by Toadcop
It's hard to realise 2 sided materials ? (so the mesh will be covered from 2 sides with textures and not as usual 1 with texture the other side is "transparent")
?
some link, info would be usuful =)

Posted: Fri Jul 04, 2008 7:07 pm
by Dorth
have the 2 opposite faces in different meshbuffers and turn on backface culling?

Posted: Sat Jul 05, 2008 5:22 am
by lostclimategames
or just turn off culling in general for that object.

Posted: Sat Jul 05, 2008 1:21 pm
by Dorth
what? That doesn't even make sense. Occlusion culling, view culling, etc. There's plenty he'll like to leave in. Also, he didn't ask for 2 textures but for 2 materials.

Posted: Sat Jul 05, 2008 5:56 pm
by christianclavet
Hi, There 2 way you can solve your problem:

First solution: You want to have the same surface but on both sides of your object. (The other side is not transparent but not drawed at all, it save time to render an object, the computer is only accounting for one side. Technical: this is done by the vertices(points) order of the face that define the face "normal")

Disable the BACKFACE CULLING for your surface: You can select your object in IRRedit then check for this in the attributes and retrieve the IRRscene file. Another way you could do this is doing this directly in IRRlicht (Check the SDK docs for enabling this for meshes attributes.

If you do it directly in your 3D modeling package:
Check for Backface culling or double sided poly attributes on your texturing panel (3DS, Lightwave, Blender, etc). If it's done directly in the 3D modeling package, you should'nt have to do it in IRRlicht or IRRedit.

Second solution: Need for different surface type on EACH side. (EX: one side is golden metal, the other side is a brick texture)

If you want to create another textures type on the backface (so in other side is having a different textures) you will have to model the other side.

The easiest way is to go in poly mode, select all polygons, copy the polygons then use the (face/poly) FLIP command, also set them another surface/texture before unselecting theses because they will be hard to select after (you'll be selecting mostly both sides)

Posted: Mon Jul 07, 2008 2:15 am
by Toadcop
christianclavet - WOW ! tnx thats what i wanted to know.
awesome explanation. and i need the first one =) so the model self will handle that.