return (jlong) ceil(1000000000/((jlong)freq.QuadPart));
if (res < 1) { res = 1; } }
JNIEXPORT jlong JNICALL Java_com_sun_j3d_utils_timer_J3DTimer_getNativeTimerResolution  (JNIEnv *env, jclass clazz) {#ifdef SOLARIS  char buf[4];  jlong res=0;  sysinfo( SI_RELEASE, &buf[0], 4 );  if (strcmp( "5.7", &buf[0] )==0) {      res = (jlong)3;  } else {      struct timespec tp;      clock_getres( CLOCK_HIGHRES, &tp );      res = (jlong)tp.tv_nsec;  }  return res;#endif#ifdef WIN32  LARGE_INTEGER freq;  QueryPerformanceFrequency( &freq );  if ( (jlong)freq.QuadPart==0 )    return 1;  return (jlong) ceil(1000000000/((jlong)freq.QuadPart));#endif#ifdef __linux__  return ((jlong)1000000000) /sysconf (_SC_CLK_TCK); #endif}