27 #ifndef _ShaderFFPLighting_
28 #define _ShaderFFPLighting_
31 #ifdef RTSHADER_SYSTEM_BUILD_CORE_SHADERS
65 virtual const String& getType ()
const;
70 virtual int getExecutionOrder ()
const;
75 virtual void updateGpuProgramsParams (Renderable* rend, Pass* pass,
const AutoParamDataSource* source,
const LightList* pLightList);
80 virtual void copyFrom (
const SubRenderState& rhs);
85 virtual bool preAddToRenderState (RenderState* renderState, Pass* srcPass, Pass* dstPass);
106 typedef vector<LightParams>::type LightParamsList;
107 typedef LightParamsList::iterator LightParamsIterator;
108 typedef LightParamsList::const_iterator LightParamsConstIterator;
128 void setLightCount (
const int lightCount[3]);
134 void getLightCount (
int lightCount[3])
const;
141 void setSpecularEnable (
bool enable) { mSpecularEnable = enable; }
146 bool getSpecularEnable ()
const {
return mSpecularEnable; }
151 virtual bool resolveParameters (ProgramSet* programSet);
156 virtual bool resolveDependencies (ProgramSet* programSet);
161 virtual bool addFunctionInvocations (ProgramSet* programSet);
167 bool addGlobalIlluminationInvocation (Function* vsMain,
const int groupOrder,
int& internalCounter);
172 bool addIlluminationInvocation (LightParams* curLightParams, Function* vsMain,
const int groupOrder,
int& internalCounter);
178 bool mSpecularEnable;
179 LightParamsList mLightParamsList;
195 static Light msBlankLight;
204 class _OgreRTSSExport FFPLightingFactory :
public SubRenderStateFactory
211 virtual const String& getType ()
const;
216 virtual SubRenderState* createInstance (ScriptCompiler* compiler, PropertyAbstractNode* prop, Pass* pass);
221 virtual void writeInstance (MaterialSerializer* ser, SubRenderState* subRenderState, Pass* srcPass, Pass* dstPass);
229 virtual SubRenderState* createInstanceImpl ();
HashedVector< Light * > LightList
LightTypes
Defines the type of light.
SharedPtr< Parameter > ParameterPtr
SharedPtr< UniformParameter > UniformParameterPtr
int TrackVertexColourType
An enumeration describing which material properties should track the vertex colours.