Clean up up osg::Geometry, removing long deprecated support for array indices and BIND_PER_PRIMITIVE binding that forced OpenGL slow paths. osg::Geometry is now smaller and only supports OpenGL fasts paths.
New methods osg::Geometry::containsDeprecatedData() and osg::Geometry::fixDeprecatedData() provide a means for converting geometries that still use the array indices and BIND_PER_PRIMITIVE across to complient versions. Cleaned up the rest of the OSG where use of array indices and BIND_PER_PRIMITIVE were accessed or used.
This commit is contained in:
@@ -250,7 +250,7 @@ bool RigTransformHardware::init(RigGeometry& geom)
|
||||
std::stringstream ss;
|
||||
ss << "boneWeight" << i;
|
||||
program->addBindAttribLocation(ss.str(), attribIndex + i);
|
||||
geom.setVertexAttribData(attribIndex + i, osg::Geometry::ArrayData(getVertexAttrib(i),osg::Geometry::BIND_PER_VERTEX));
|
||||
geom.setVertexAttribArray(attribIndex + i, getVertexAttrib(i));
|
||||
OSG_INFO << "set vertex attrib " << ss.str() << std::endl;
|
||||
}
|
||||
program->addShader(_shader.get());
|
||||
|
||||
Reference in New Issue
Block a user