]> git.mxchange.org Git - simgear.git/blobdiff - simgear/scene/tgdb/ShaderGeometry.cxx
hla: Provide a directly property based api for property data element.
[simgear.git] / simgear / scene / tgdb / ShaderGeometry.cxx
index 089beb270c56e5ac56632406885d629ae1f9e564..36a3093471cb628e5e603c29ef4cec8861ba397f 100644 (file)
@@ -32,14 +32,15 @@ using namespace osgDB;
 
 namespace simgear
 {
-void ShaderGeometry::addTree(const TreeBin::Tree& t)
+void ShaderGeometry::addObject(const Vec3& position, float scale,
+                               int texture_index)
 {
     if (!_posScaleArray.valid()) {
         _posScaleArray = new Vec4Array();
         _vertexAttribArray = new FloatArray();
     }
-    _posScaleArray->push_back(Vec4(t.position.osg(), t.scale));
-    _vertexAttribArray->push_back((float)t.texture_index / varieties);
+    _posScaleArray->push_back(Vec4(position, scale));
+    _vertexAttribArray->push_back((float)texture_index / varieties);
     dirtyBound();
 }