I want to implement an effect that uses the 'alpha' colour value of a material. In the old engine we use the following code to do the effect:
// calc the alpha value
float alpha = "some code"
// set the color
glColor4f(1.0f, 1.0f, 1.0f, alpha)
// render the polys
glBegin(GL_TRIANGLES)
"etc...etc..."
glEnd()
I've porting the engine to use ogre and I need to do something like this:
(given Ogre::MaterialPtr m_pmaterial)
// calc the alpha value
float alpha = "some code"
// set the materials colour
m_pmaterial->setAmbient(1.0f, 1.0f, 1.0f, alpha)
however the Ogre::Material classes setAmbient only takes 3 parameters (red, green, and blue), - no alpha?
How can I do this in ogre? hm....





