ofxHapPlayer
ofxHapPlayer copied to clipboard
Varying frame rates for long movies when calling getCurrentFrame();
If you play a movie and use getCurrentFrame() then the movie framerate get progressively slower until the end of the movie. For a movie that's 130 sec long the rendering FPS goes from 700fps at the start of the movie to 30fps by then end. For a 10min movie it gets much lower to the point of being unwatchable.
This has been tested with ofx 0.8.4 and 0.9 under both windows and osx using both glut and glfw for the windowing toolkit. The easiest way to reproduce things is to add the below line to the example and swap the example movie for something a bit longer.
ofDrawBitmapString("Frame: " + ofToString(movie.getCurrentFrame()), 10, 45);
yea, get/setCurrentFrame have to step through the movie until they get to the frame - it's not ideal. Using get/setPosition is faster.