diff --git a/colorchord2/main.c b/colorchord2/main.c index 177a9fa..4b96829 100644 --- a/colorchord2/main.c +++ b/colorchord2/main.c @@ -3,7 +3,6 @@ #if defined(WIN32) || defined(USE_WINDOWS) #include #include -#define strdup _strdup #endif #include @@ -346,8 +345,12 @@ int main(int argc, char ** argv) WSAStartup(0x202, &wsaData); + #ifdef TCC + REGISTERWinCNFA(); REGISTERcnfa_wasapi(); - strcpy( sound_source, "WASAPI" ); + #endif + + strcpy( sound_source, "WASAPI" ); // Use either "sound_source=WASAPI" or "sound_source=WIN" in config file. #elif defined( ANDROID ) strcpy( sound_source, "ANDROID" ); @@ -449,7 +452,11 @@ int main(int argc, char ** argv) Now = OGGetAbsoluteTime(); double Last = Now; - while( !headless ) + #ifdef ANDROID + while(!bQuitColorChord) + #else + while(!headless) + #endif { char stt[1024]; //Handle Rawdraw frame swappign diff --git a/colorchord2/windows/compile.bat b/colorchord2/windows/compile.bat index f8f48cc..9ab2847 100644 --- a/colorchord2/windows/compile.bat +++ b/colorchord2/windows/compile.bat @@ -19,4 +19,5 @@ rem set CC=C:\tcc\i386-win32-tcc.exe rem set CC=C:\tcc\x86_64-win32-tcc.exe @echo on %CC% %CFLAGS% %INCLUDES% %ARCH_SPECIFIC% %SOURCES% %LDFLAGS% -o ..\colorchord.exe -pause +@echo off +pause \ No newline at end of file