From a2e1bf3495b7bfefdaedb8fc737e969ab06df079 Mon Sep 17 00:00:00 2001 From: Tim Redfern Date: Wed, 4 Sep 2013 16:41:30 +0100 Subject: cycler cut to next available slot --- rotord/src/graph.cpp | 14 +++++++------- rotord/src/rotor.h | 8 +++++++- 2 files changed, 14 insertions(+), 8 deletions(-) diff --git a/rotord/src/graph.cpp b/rotord/src/graph.cpp index ae9247b..ef5fd87 100644 --- a/rotord/src/graph.cpp +++ b/rotord/src/graph.cpp @@ -78,13 +78,13 @@ bool Graph::preview(xmlIO &XML,string &node,string &_format,int frame,int w,int } bool Graph::video_render(const string &output_filename,const float framerate,float& progress) { - vector loaders=find_nodes("video_loader"); - for (auto i:loaders){ - if (!dynamic_cast(i)->isLoaded) { - cerr<<"Rotor: all loaders must be populated before rendering"< loaders=find_nodes("video_loader"); + //for (auto i:loaders){ + // if (!dynamic_cast(i)->isLoaded) { + // cerr<<"Rotor: all loaders must be populated before rendering"<(find_node("video_output")); for (auto f: find_nodes("video_feedback")){ diff --git a/rotord/src/rotor.h b/rotord/src/rotor.h index d6426f5..20089b8 100755 --- a/rotord/src/rotor.h +++ b/rotord/src/rotor.h @@ -430,7 +430,13 @@ namespace Rotor { } return nullptr; } - return image_inputs[((int)inputs[0]->get((Time_spec)frame))%image_inputs.size()]->get(frame); + //cut mode + for (int i=0;iget((Time_spec)frame)+i)%image_inputs.size(); + Image *in=image_inputs[whichinput]->get(frame); + if (in) return in; + } + return nullptr; } Video_cycler* clone(map &_settings) { return new Video_cycler(_settings);}; }; -- cgit v1.2.3