procedure texture mapping

I want to generate and map texture in different pattern to a model surface basing on different average light density of different regions. The input model is triangle mess. And I don’t want to do this with the support of pixel shadder. How to do with this procedural texture mapping?

Any source example code about procedural texture mapping is most helpful.Because I have no concept on the implementation of procedural texture mapping within OPENGL’s rendering pipeline.(My case is 2 dimension procedural texture mapping region by region, not 1D pixel by pixel)

Thanks a lot!!!

I can’t think of a way to do what I think you are talking about. If you want a procedural texture, generated at run time, there are two ways to do it: generate the texture on the CPU and load it into a texture map, and to use a fragment shader.

If you want to have a function of lighting, thefragment shader will probably be the easy way since you’ll get stuff for free. However I’m not sure what you mean by “basing on different average light density of different regions”.