fps. TODO: move to openGL