I want to write a vertex lighting shader by my own, but I have the problem, that the glstate built-ins doesn’t work for me. Do I make the mistake or is it another issue? There is one directional light in the scene which is forced as vertex light.
My test vertex shader that doesn’t react to modifications to light color:
Perhaps a bit late, but that is exactly what is done in the Unite 2008 presentation on Shaders.
Download the .mov, and skip to about 1:50, where he starts calculating lighting per pixel. He uses the glstate variables in the fragment function, and it works fine…