the (float) casts are redundant. compiler will auto promote due to frameRate