video file fast random access, maybe ofFbo array? vector?

I’m trying to play a video in random frames according to some parameters real fast.
I’m already using some good video codecs for random access, tried to run the software from a RAM disk too
I was wondering if an array of ofFbo would work. I dont even know if its doable, suggestions are welcome. Wondering about vectors too.

  
  
ofFbo ** fboVideo;  
vector<ofVideoPlayer> videos;  
lister_videos.listDir("videos/");  
videos.assign(lister_videos.size(), ofVideoPlayer());  
  
fboVideo = new ofFbo * [lister_videos.size()];  
for (int i = 0; i < lister_videos.size(); i++) {  
	fboVideo[i] = new ofFbo[videos[i].getTotalNumFrames()];  
	for (int j=0; j<videos[i].getTotalNumFrames(); j++) {  
		fboVideo[i][j].allocate(outputDimensions.x, outputDimensions.y, GL_RGBA);  
		fboVideo[i][j].begin();  
		videos[i].setFrame(j);  
		videos[i].draw(0,0,outputDimensions.x, outputDimensions.y);  
		fboVideo[i][j].end();  
	}  
}  
  

FBOs are only important when you need to draw into something.

if you’re drawing from something, you should use a texture (ofTexture). so i recommend you create a vector and load your frames into each texture.

Yeah, you want textures, not fbos, especially not a lot of fbos. This thread might be helpful in getting started: http://forum.openframeworks.cc/t/simple-ofvideoplayer-problem/7458/0

Thanks Kyle and Joshua