Per pixel lighting shader program

Problems building or running the engine, queries about how to use features etc.
Nocs
Halfling
Posts: 48
Joined: Wed Dec 29, 2004 3:20 pm

Per pixel lighting shader program

Post by Nocs »

Hello,

how can i set up a material with per pixel lighting (diffuse / specular) calculated by a shader program?
How can i set up per pixel lighting in software mode?

Thanks
User avatar
sinbad
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 19269
Joined: Sun Oct 06, 2002 11:19 pm
Location: Guernsey, Channel Islands
x 66

Post by sinbad »

Demo_Dot3Bump does per-pixel lighting, with normal mapping in that case but you don't have to use that. Look at the .material scripts and the shaders which go with them to see how it's done, and read the manual if you don't understand them.

Per-pixel lighting is not possible in software mode. We don't support software emulation of shaders because it's a pointlessly slow exercise.