grid func and framerate