NPR (Blender Internal) - Shadeless material that is effected by light

Hi everyone,

after googling did not turn up anything useful, I try to find an answer here in the forums. :wink:

I’ve been working on non-photorealistic renderings (pixel art, cel shading, etc.). I get by fine with the toon material and emission. But one material property that could come in very useful would be to have a shadeless material that is still affect by light, but only in brightness and tint for the whole material, without showing any shading or shadows.

So, say an evenly lit character approaches a point light the whole character would start getting brighter - just like in older gaming engines.

Is there any way of achievingthis?

With nodes, you can have access to lights position and distance (Blender Internal and GE only). Then is just a matter of using that info to drive changes in your material.

Thanks! I’m not super experienced with the node system but it sounds like something I might be able to do. :slight_smile: Will give it a try!

here’s an example:


Thank you! I got close but I didn’t quite get it to work (was missing the ColorRamp and didn’t know how to calculate the distance with the math node). This works a treat!

Only thing I would love is for all lights in the scene to act on the material, not a specific one. Makes it much more complicated to deal with.

You can try to use the ramp option from the diffuse/specular color… they have a ‘energy’ input for the ramp. It may not be as versatile as using nodes but if it works, good. With nodes, i think you need to add a node for each lamp and perform something to all the distances (using the ‘minimum’ might do the trick, but there are other options).

Thanks, I will look into all of that!