fixed framerate calculation.