Changeset 1899f0d


Ignore:
Timestamp:
Oct 1, 2006, 5:13:00 PM (18 years ago)
Author:
Paul Brossier <piem@altern.org>
Branches:
feature/autosink, feature/cnn, feature/cnn_org, feature/constantq, feature/crepe, feature/crepe_org, feature/pitchshift, feature/pydocstrings, feature/timestretch, fix/ffmpeg5, master, pitchshift, sampler, timestretch, yinfft+
Children:
8131a5c
Parents:
32c0133
Message:

hack around timer.c to pass compilation on windows
hack around timer.c to pass compilation on windows

File:
1 edited

Legend:

Unmodified
Added
Removed
  • ext/midi/timer.c

    r32c0133 r1899f0d  
    4141#if 0
    4242#include <winbase.h>
     43#endif
    4344
    4445struct _aubio_timer_t
     
    7475
    7576  if (new_thread) {
     77#if 0
    7678    timer->thread = CreateThread(NULL, 0, aubio_timer_run, (LPVOID) timer, 0, &timer->thread_id);
     79#endif
    7780    if (timer->thread == NULL) {
    7881      AUBIO_ERR( "Couldn't create timer thread");     
     
    8083      return NULL;
    8184    }
     85#if 0
    8286    SetThreadPriority(timer->thread, THREAD_PRIORITY_TIME_CRITICAL);
     87#endif
    8388  } else {
    8489    aubio_timer_run((LPVOID) timer);
     
    9095aubio_timer_run(LPVOID data)
    9196{
     97#if 0
    9298  int count = 0;
    9399  int cont = 1;
     
    131137
    132138  ExitThread(0);
     139#endif
    133140  return 0;
    134141}
     
    146153aubio_timer_join(aubio_timer_t* timer)
    147154{
     155#if 0
    148156  DWORD wait_result;
    149157  if (timer->thread == 0) {
     
    152160  wait_result = WaitForSingleObject(timer->thread, INFINITE);
    153161  return (wait_result == WAIT_OBJECT_0)? AUBIO_OK : AUBIO_FAIL;
     162#else
     163  return 0;
     164#endif
    154165}
    155166/***************************************************************
     
    177188double rdtsc(void)
    178189{
     190#if 0
    179191  LARGE_INTEGER t;
    180192  QueryPerformanceCounter(&t);
    181193  return (double) t.QuadPart;
     194#else
     195  return 0.;
     196#endif
    182197}
    183198
     
    210225
    211226#else
     227#if 0
    212228  unsigned int before, after;
    213229  LARGE_INTEGER start, stop;
     
    223239  return (double) 1000 * (stop.QuadPart - start.QuadPart) / (after - before);
    224240#endif
    225 }
    226 
    227 #endif
     241  return 0;
     242#endif
     243}
     244
    228245
    229246
Note: See TracChangeset for help on using the changeset viewer.