diff options
Diffstat (limited to 'rotord/rotor.h')
| -rwxr-xr-x | rotord/rotor.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/rotord/rotor.h b/rotord/rotor.h index e128fd5..d8ee021 100755 --- a/rotord/rotor.h +++ b/rotord/rotor.h @@ -486,7 +486,7 @@ namespace Rotor { base_settings(settings); divide_amount=ofToFloat(find_setting(settings,"amount")); for (auto p:parameter_inputs){ - if (p->parameter=="divide_amount") p->receiver=÷_amount; + if (p->parameter=="amount") p->receiver=÷_amount; } }; Signal_divide* clone(map<string,string> &_settings) { return new Signal_divide(_settings);}; @@ -789,7 +789,10 @@ namespace Rotor { if (p->parameter=="mode") p->receiver=&mode; } }; - ~Echo_trails(){if (image) {delete image;} }; + //~Echo_trails(){if (image) {delete image;} }; + ~Echo_trails(){ + for (auto i:images) {delete i.second;} + }; Image *output(const Frame_spec &frame){ //check if cache is valid if (frame.w!=image->w||frame.h!=image->h){ //or framerate changed? @@ -857,7 +860,7 @@ namespace Rotor { return nullptr; } Echo_trails* clone(map<string,string> &_settings) { return new Echo_trails(_settings);}; - private: + protected: float duration,fadeto; int number; int interval,total,lastframe; //number of frames between displayed echoes @@ -868,6 +871,9 @@ namespace Rotor { class Node_factory{ public: Node_factory(); + ~Node_factory(){ + for (auto t:type_map) delete t.second; + } void add_type(string type,Node* proto){ type_map[type]=proto; }; @@ -938,6 +944,7 @@ namespace Rotor { output_framerate=25.0f; audio_loaded=false; }; + ~Render_context(){delete audio_thumb;}; void runTask(); void add_queue(int item); Command_response session_command(const std::vector<std::string>& command); |
