- Home /
How to light back side of quad mesh same way as front side?
Normally, when lighting effect applied to quad/plane(or any paper) mesh, one side is bright and the other side becomes darker. But I want both sides of the mesh to be lit as if both sides are facing light source to make them brighter for some game scene.
I assume this is shader's work but I've never written one so have no idea where to start. Could anyone give me some hint? Thanks.
[Edit] When I tried Cull Off shader with quad/plane mesh, it did give both sides of the mesh same lighting but when the front-side is not lit, neither does the back-side.
Do you really need light? If not, you can go with an unlit shader that is built-in in Unity. If you do, then yes, shading is the way to go.
If you're new to shder code. I'd suggest taking a look into this tutorial
To make everything light up evenly you can use to directional lights in opposition to each other
Yes, light has a big role in my game. I can't use ambient color or directional lights because the scene takes place in night and it should be complete dark where lights are not lit.
Answer by Eric5h5 · May 22, 2014 at 12:38 AM
Just use a single-sided quad and put "cull off" in the shader. Then both sides will be rendered with the same lighting.
It partially worked but when the active side doesn't receive light, same goes to the other side -.- I have uploaded a picture
It seems setting dummy blank normal map with "cull off" fixed this problem. I have no idea why... I will accept and close the question after testing a little more
Your answer
Follow this Question
Related Questions
Odd shadow effect, help! 1 Answer
Lighting problem 0 Answers
How to create light like in minecraft? 1 Answer
Semitransparent shader not visible in front of objects 1 Answer
Custom Sprite Shader Ignore Light 1 Answer