]> git.mxchange.org Git - simgear.git/commitdiff
Ensure compatibility with OSG 3.1.8.
authorAlex Romosan <romosan@sycorax.lbl.gov>
Wed, 26 Jun 2013 21:53:07 +0000 (23:53 +0200)
committerThomas Geymayer <tomgey@gmail.com>
Wed, 26 Jun 2013 21:54:09 +0000 (23:54 +0200)
simgear/scene/material/EffectGeode.cxx

index 26eab3852fdf6715864c23581c5a3af359dcee9a..6119f107719cf60f73f058daa7f5d46ca962a024 100644 (file)
@@ -80,15 +80,15 @@ void EffectGeode::runGenerators(osg::Geometry *geometry)
         int n = _effect->getGenerator(Effect::TANGENT);
         tsg->generate(geometry, 0);  // 0 is normal_unit, but I have no idea what that is!
         if (n != -1 && !geometry->getVertexAttribArray(n))
-            geometry->setVertexAttribData(n, osg::Geometry::ArrayData(tsg->getTangentArray(), osg::Geometry::BIND_PER_VERTEX,GL_FALSE));
+          geometry->setVertexAttribArray(n, tsg->getTangentArray());
 
         n = _effect->getGenerator(Effect::BINORMAL);
         if (n != -1 && !geometry->getVertexAttribArray(n))
-            geometry->setVertexAttribData(n, osg::Geometry::ArrayData(tsg->getBinormalArray(), osg::Geometry::BIND_PER_VERTEX,GL_FALSE));
+          geometry->setVertexAttribArray(n, tsg->getBinormalArray());
 
         n = _effect->getGenerator(Effect::NORMAL);
         if (n != -1 && !geometry->getVertexAttribArray(n))
-            geometry->setVertexAttribData(n, osg::Geometry::ArrayData(tsg->getNormalArray(), osg::Geometry::BIND_PER_VERTEX,GL_FALSE));
+          geometry->setVertexAttribArray(n, tsg->getNormalArray());
     }
 }