1 #ifndef R2C2_3D_CATALOGUE_H_
2 #define R2C2_3D_CATALOGUE_H_
4 #include <msp/datafile/collection.h>
5 #include <msp/fs/path.h>
6 #include <msp/gl/material.h>
7 #include <msp/gl/mesh.h>
8 #include "libr2c2/catalogue.h"
16 class Catalogue3D: public Msp::DataFile::Collection
20 std::map<const TrackType *, TrackType3D *> tracks;
21 std::map<const VehicleType *, VehicleType3D *> vehicles;
22 std::map<const SignalType *, SignalType3D *> signals;
23 Msp::GL::Mesh endpoint_mesh;
26 Catalogue3D(Catalogue &);
29 const Catalogue &get_catalogue() const { return catalogue; }
30 const TrackType3D &get_track(const TrackType &) const;
31 const VehicleType3D &get_vehicle(const VehicleType &) const;
32 const SignalType3D &get_signal(const SignalType &) const;
33 const Msp::GL::Mesh &get_endpoint_mesh() const { return endpoint_mesh; }
35 void track_added(const TrackType &);
36 void vehicle_added(const VehicleType &);
37 void signal_added(const SignalType &);
38 void build_endpoint_mesh();
40 Msp::FS::Path locate_file(const std::string &);
43 T *create(const std::string &);
46 T *create2(const std::string &);