Rendering and saving a list of images

this is a newbie vvvv question:

we are rendering a series of textures and saving them to file. the logical order for this should be:

  1. load first image from file
  2. render with a transform to a texture
  3. save this texture

then go back to 1.

currently we have solved moving to the next image with a delay that then increments a counter. however, this is unsatisfactory and is either wasting time or too fast in which case the program fails.

as there is no ‘done’ bang output from either a renderer or the writer we don’t know when the rendering or writing is done and when to move to the next image. i am assuming this is a solved problem as i can’t be the first one to try this, but i can’t figure it out. any help would be much appreciated.

hei mo,

here is some general info on recording output: faq rendering#how to capture the output of a renderer

the reason for there not being a “done” output on the renderer or the writer is that it is “done” as soon as the next frame starts. ie. the mainloop is blocked for as long as any node needs to finish its task for the current frame.

therefore you could consider setting the Up on Counter (Animation) to 1 all the time or probably using FrameCounter (Animation).

ok thanks for that. so if ive understood you correctly, what you are saying is that i don’t need to worry about concurrency or ordering, this is all take care of.

in that case, then all i need to do is find a way to increment my counter as i need and index to fetch the correct file name and transform vectors. so i do need to set an “up” on the counter, but i am not sure where i would get this “up” from?

hm?! but the “up” is only a constant 1 on the Up of the Counter (Animation), right? and you know how to make a constant 1? create a value iobox, set it to 1 and connect it to the Up.

ok i think i didn’t get that first time around because the “up” is a bang, isn’t it? but i guess you are saying when the bang input is being evaluated this implicitly means the loop is done, and so it can stay at 1 all the time and we still get an incrementing counter. this is great of course. will try. thanks