- build_part(*i, rail_profile, Point(gauge/2-rail_min.x, y), bld, index);
+ build_part(*i, rail_profile, Vector(gauge/2, y), false, bld, index);
+
+ object = new GL::Object;
+ object->set_mesh(mesh);
+ object->set_technique(catalogue.get<GL::Technique>(cat.get_track_technique()));
+ }
+
+ unsigned paths = tt.get_paths();
+ for(unsigned i=0; paths; ++i, paths>>=1)
+ {
+ GL::Mesh *m = 0;
+ if(paths&1)
+ {
+ m = new GL::Mesh(GL::VERTEX3);
+ GL::MeshBuilder bld(*m);
+ unsigned index = 0;
+ for(vector<TrackPart>::const_iterator j=parts.begin(); j!=parts.end(); ++j)
+ if(j->get_path()==i)
+ build_part(*j, cat.get_path_profile(), Vector(0, ballast_h+1.5*rail_h), false, bld, index);
+ }
+ path_meshes.push_back(m);