1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
|
/*
SuperCollider real time audio synthesis system
Copyright (c) 2002 James McCartney. All rights reserved.
http://www.audiosynth.com
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*/
#pragma once
#ifdef _WIN32
# ifdef IN
# define SC_IN IN
# undef IN
# endif
# ifdef OUT
# define SC_OUT OUT
# undef OUT
# endif
# include <stdio.h>
# include <winsock2.h>
# undef IN
# undef OUT
# ifdef SC_IN
# define IN SC_IN
# endif
# ifdef SC_OUT
# define OUT SC_OUT
# endif
// wrappers for unix replacements
# define basename win32_basename
# define dirname win32_dirname
# define pipe win32_pipe
# if _MSC_VER
typedef int pid_t;
# endif
void win32_ReplaceCharInString(char* string, int len, char src, char dst);
// Finds the parent folder of a specified path pattern (including trailing slash)
void win32_ExtractContainingFolder(char* folder, const char* pattern, int maxChars);
void win32_GetKnownFolderPath(int folderId, char* dest, int size);
void win32_synctimes();
char* win32_basename(char* path);
char* win32_dirname(char* path);
int win32_pipe(int handles[2]);
int win32_piperead(int s, char* buf, int len);
int win32_pipewrite(int s, char* buf, int len);
// alloca
# include <malloc.h>
# ifndef alloca // MinGW has alloca defined in malloc.h, MSVC not
# define alloca _alloca
# endif
#endif //_WIN32
|