X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2F3d%2Flayout.h;h=a7fbdb98b9dbc7b7751ce2e26470403dd647c85d;hb=47341c72a70e6cf9d8e963705a50197bbc20a87d;hp=d469dc9aea9af1e2b2f04057912e927b0a767703;hpb=1d735b80482317fd930eb47ca255ab9f1f120a7d;p=r2c2.git diff --git a/source/3d/layout.h b/source/3d/layout.h index d469dc9..a7fbdb9 100644 --- a/source/3d/layout.h +++ b/source/3d/layout.h @@ -1,7 +1,16 @@ +/* $Id$ + +This file is part of the MSP Märklin suite +Copyright © 2006-2010 Mikkosoft Productions, Mikko Rasa +Distributed under the GPL +*/ + #ifndef MARKLIN3D_LAYOUT_H_ #define MARKLIN3D_LAYOUT_H_ +#include #include "libmarklin/layout.h" +#include "catalogue.h" #include "track.h" namespace Marklin { @@ -9,19 +18,29 @@ namespace Marklin { class Layout3D { private: - Layout &layout; + Layout &layout; + Catalogue3D catalogue; std::list tracks; - unsigned quality; + Msp::GL::Scene scene; + Msp::GL::Scene ep_scene; + unsigned quality; public: Layout3D(Layout &); ~Layout3D(); + const Catalogue3D &get_catalogue() const { return catalogue; } void set_quality(unsigned); + + void add_track(Track3D &); + void remove_track(Track3D &); const std::list &get_tracks() const { return tracks; } - void render(bool =false) const; Track3D &get_track(const Track &) const; Track3D *pick_track(float, float, float) const; + + Msp::GL::Scene &get_scene() { return scene; } + Msp::GL::Scene &get_endpoint_scene() { return ep_scene; } + private: void track_added(Track &); void track_removed(Track &);