depending on how long of a video you want to record, could you do this with an array for textures (or fbos) or one larger one that you draw multiple frames into?
this functionality is not built into OF but it shouldn’t be hard to make something that records a sequence on GPU and loops it…
I have a c++ syntax question that I can’t seem to sort out.
I’d like to make an vector of vector of textures, and i’d like to initialize the sizes in my .h file.
If you want to define a type (to make things a little more terse), you can do something like this:
typedef std::vector<ofTexture> BufferType; // This creates an alias for a vector of textures.
std::vector<BufferType> buffArray; // This uses that alias and is eqiv to:
std::vector<std::vector<ofTexture>> buffArray
Template parameters must be concrete types, not variables (buf in your last example is a static variable of type vector<ofTexture> buf;.
I often use this in classes where I’m using a complex type and I don’t want to type it out every time. e.g.
Also, if you are using fixed size std::vector you might also consider the new std::array type, which gives you std::vector like behavior, but is essentially a good old fashioned c++ array.