Hi!
I am using the standard ParallaxBump/Diffuse Shader on one of my indoor scenes. Whenever i use a directional light, the light wanders around the texture as desired. When i use a spotlight it doesnt do anything to the bump effect…
Doesnt this shader work with spotlights (global effect only?) or did i miss something?
Thanks in advance!
Frank
Is the spotlight set to a pixel light? (Pixel lighting is required to render bumpmaps.)
Yes it is… it gives a bumped effect. But when i rotate it, it doesent change the bump effect at all. The bump remains static. When i do the same action with a directional light, the shadow and highlight move with the light direction…
There’s a fundamental difference:
Directional lights have only the direction - position doesn’t modify bumps. So the direction of the incoming light on a surface is only modified by rotating the light (and not moving it)
For point lights, you the direction of the incoming light is defined by the direction from the surface being lit to the light. Hence rotating a point light doesn’t do anything (whereas moving it will)
Spotlights work just like point lights, except they are darkened out along all sides save one.
In short, just move your spot/point light, and it’ll work just fine.
Thanks a lot!
Just the info i needed (and works fine as well
)