Fixed bug in frame rate.