A non-shader path for terrain
The current pixel shader for terrain is getting too large, and fails on (some) SM 2.0 cards. The number of lights has to be lowered down to 3, otherwise I get the error "r300_fragprog_emit.c::emit_alu(): Too many ALU instructions" and the terrain ends up almost all black. And even when the number of lights is at 3, the colors are funky and performance is quite poor.
If I recall correctly, vanilla Morrowind only required ps 1.1 for it's optional water shader, and otherwise didn't need them. Since OpenMW allows disabling shaders on objects and water, it'd be nice if at least pixel shaders could be disabled for terrain (as far as I can tell, vertex shaders are fine; but disabling pixel shaders would very likely give a nice boost and provide an increase in the number of usable lights due to vertex lighting).
To contrast, I get a large jump in performance when I disable shaders for objects, even compared to when the number of lights is at 4.
(RM-278 from redmine: created on 2012-05-01 by Chris Robinson, , closed on 2012-06-28 by nobody, relates #315 (closed))