X-Git-Url: http://git.tdb.fi/?p=netvis.git;a=blobdiff_plain;f=source%2Fport.h;fp=source%2Fport.h;h=8877ed9067df827cf8a332503d0bf1b72b42b835;hp=4ce9427fc6df5b6913afd0743e8a8fb38dbe9a22;hb=afeb198dfbe4929c8d95487bca64a84ec3b92148;hpb=9954e8cbf9bae21f5a727f9c92e9c33dc6d8eaf1 diff --git a/source/port.h b/source/port.h index 4ce9427..8877ed9 100644 --- a/source/port.h +++ b/source/port.h @@ -11,6 +11,7 @@ Distributed unter the GPL #include #include #include +#include "activity.h" class NetVis; @@ -23,6 +24,7 @@ private: std::string name; Msp::GL::Color color; Msp::GL::Mesh mesh; + Activity activity; public: Port(NetVis &, unsigned); @@ -32,6 +34,11 @@ public: const std::string &get_name() const { return name; } const Msp::GL::Color &get_color() const { return color; } + void add_activity(unsigned); + float get_activity() const { return activity.get_average(); } + + void tick(const Msp::Time::TimeDelta &); + void render() const; };