From: OSHIRO Naoki To: vision Subject: ftime-test.c Date: Wed, 25 Feb 1998 18:45:21 +0900 (JST) Message-Id: <199802250945.SAA06159@tecA229.tec.u-ryukyu.ac.jp> Sample of ftime(): /* * ftime-test.c: * * [1998/02/25] OSHIRO Naoki. * * $Log:$ */ static char rcsid[]="$Id:$"; #include #include #include #include int main(void) { struct timeb cur_t, pre_t; float stime; int i; ftime(&cur_t); pre_t=cur_t; for (i=0; i<2000; i++) { ftime(&cur_t); stime=cur_t.time-pre_t.time +(cur_t.millitm-pre_t.millitm)/1000.0; printf("time:%6.3f\n", stime); pre_t=cur_t; scanf("%*c\n"); } }