Fixed handling of GL function pointer setup for GLES1/GLES2 targets

Dropped the fixed function pipeline defaults from  StateSet and SceneView.
This commit is contained in:
Robert Osfield
2009-11-03 11:10:41 +00:00
parent 9c5409ad8a
commit 08903d65a1
5 changed files with 70 additions and 49 deletions

View File

@@ -533,12 +533,17 @@ void StateSet::setGlobalDefaults()
setMode(GL_DEPTH_TEST,StateAttribute::ON);
// setAttributeAndModes(new AlphaFunc,StateAttribute::OFF);
setAttributeAndModes(new BlendFunc,StateAttribute::OFF);
Material *material = new Material;
material->setColorMode(Material::AMBIENT_AND_DIFFUSE);
setAttributeAndModes(material,StateAttribute::ON);
#if !defined(OSG_GLES2_AVAILABLE)
// setAttributeAndModes(new AlphaFunc,StateAttribute::OFF);
setAttributeAndModes(new BlendFunc,StateAttribute::OFF);
Material *material = new Material;
material->setColorMode(Material::AMBIENT_AND_DIFFUSE);
setAttributeAndModes(material,StateAttribute::ON);
#endif
}