You are an experienced programmer and have a problem with the engine, shaders, or advanced effects? Here you'll get answers. No questions about C++ programming or topics which are answered in the tutorials!
well I have no idea, but I was so excited by your post that I did have a quick look in the source engine's source, and found this in IMaterialRenderer.h
virtual void setBasicRenderStates(const SMaterial& material,
const SMaterial& lastMaterial,
bool resetAllRenderstates) = 0;
//! Sets a constant for the vertex shader based on a name. This can be used if you used
//! a high level shader language like CG or HLSL to create a shader. Example: If you
//! created a shader which has variables named 'mWorldViewProj' (containing the
//! WorldViewProjection matrix) and another one named 'fTime' containing one float,
//! you can set them in your IShaderConstantSetCallBack derived class like this:
//! \code
//! virtual void OnSetConstants(video::IMaterialRendererServices* services)
//! {
//! video::IVideoDriver* driver = services->getVideoDriver();
//!
//! float time = (float)os::Timer::getTime()/100000.0f;
//! services->setVertexShaderConstant("fTime", &time, 1);
//!
//! core::matrix4 worldViewProj;
//! worldViewProj = driver->getTransform(video::ETS_PROJECTION);
//! worldViewProj *= driver->getTransform(video::ETS_VIEW);
//! worldViewProj *= driver->getTransform(video::ETS_WORLD);
//! services->setVertexShaderConstant("mWorldViewProj", worldViewProj.M, 16);
//! }