FPSCounter: Add "Log render time to file" feature.

Allows for a more accurate performance measurement than the FPS log feature.
please keep care about marking statics as static