Calculating frame rate


Im looking for a way to determine exactly how long the rendering of each frame takes (in ms). Does anyone know how to do this? Im using C++ and MFC.


Use timeGetTime(). It will return the current systemtime in ms. You can also use the more acurate QueryPerformanceCounter().