chris@164: /* chris@164: * chris@164: * 1-D string consisting of two waveguides and junction chris@164: * chris@164: * Christian Heinrichs 04/2015 chris@164: * chris@164: */ chris@164: chris@164: #ifndef STRING_H_ chris@164: #define STRING_H_ chris@164: chris@164: #include chris@164: #include "Junction.h" chris@164: #include "Waveguide.h" chris@164: chris@164: class String chris@164: { chris@164: chris@164: public: chris@164: chris@164: String(); chris@164: float update(float in); chris@164: chris@164: float getPlectrumDisplacement(); chris@164: void setMidinote(float midinote); chris@164: void setFrequency(float frequency); chris@164: void setPeriod(float periodInMs); chris@164: void setPluckPosition(float pluckPos); chris@164: void setGlobalPosition(float pos); chris@164: float getGlobalPosition(); chris@164: chris@164: private: chris@164: chris@164: float _previous_l; chris@164: float _previous_r; chris@164: chris@164: float _globalPosition; chris@164: chris@164: Waveguide wg_l; chris@164: Waveguide wg_r; chris@164: Junction junction; chris@164: chris@164: }; chris@164: chris@164: #endif