This is clock.h in view mode; [Download] [Up]
#include <sys/types.h> #include <sys/time.h> #include <sys/timeb.h> struct timeb Tbegin; struct timeb Tend; void timeBegin() { int res = ftime(&Tbegin); } void timeEnd() { int res = ftime(&Tend); } double timeDiff() { double res = (Tend.time - Tbegin.time) ; res += ((float)(Tend.millitm)/1000) - ((float)(Tbegin.millitm)/1000) ; return res ; }
These are the contents of the former NiCE NeXT User Group NeXTSTEP/OpenStep software archive, currently hosted by Netfuture.ch.