home *** CD-ROM | disk | FTP | other *** search
/ Chip 2004 November / CMCD1104.ISO / Software / Complet / ZynAddFX / Setup_ZynAddSubFX-2.1.1.exe / Config.h < prev    next >
Encoding:
C/C++ Source or Header  |  2004-09-30  |  1.8 KB  |  65 lines

  1. /*
  2.   ZynAddSubFX - a software synthesizer
  3.  
  4.   Config.h - Configuration file functions
  5.   Copyright (C) 2003-2004 Nasca Octavian Paul
  6.   Author: Nasca Octavian Paul
  7.  
  8.   This program is free software; you can redistribute it and/or modify
  9.   it under the terms of version 2 of the GNU General Public License 
  10.   as published by the Free Software Foundation.
  11.  
  12.   This program is distributed in the hope that it will be useful,
  13.   but WITHOUT ANY WARRANTY; without even the implied warranty of
  14.   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  15.   GNU General Public License (version 2) for more details.
  16.  
  17.   You should have received a copy of the GNU General Public License (version 2)
  18.   along with this program; if not, write to the Free Software Foundation,
  19.   Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
  20.  
  21. */
  22.  
  23. #ifndef CONFIG_H
  24. #define CONFIG_H
  25. #include "../globals.h"
  26. #define MAX_STRING_SIZE 4000
  27. #define MAX_BANK_ROOT_DIRS 100
  28.  
  29. class Config{
  30.     public:
  31.     Config();
  32.     ~Config();
  33.     struct {
  34.         char *LinuxOSSWaveOutDev,*LinuxOSSSeqInDev;
  35.         int SampleRate,SoundBufferSize,OscilSize,SwapStereo;
  36.         int WindowsWaveOutId,WindowsMidiInId;
  37.         int BankUIAutoClose;
  38.         int DumpNotesToFile,DumpAppend;
  39.         int GzipCompression;
  40.         int Interpolation;
  41.         char *DumpFile;
  42.         char *bankRootDirList[MAX_BANK_ROOT_DIRS],*currentBankDir;
  43.         char *presetsDirList[MAX_BANK_ROOT_DIRS];
  44.         int CheckPADsynth;
  45.         int UserInterfaceMode;
  46.     } cfg;
  47.     int winwavemax,winmidimax;//number of wave/midi devices on Windows
  48.     int maxstringsize;
  49.     
  50.     struct winmidionedevice{
  51.         char *name;
  52.     };
  53.     winmidionedevice *winmididevices;
  54.  
  55.     void clearbankrootdirlist();
  56.     void clearpresetsdirlist();
  57.     
  58.     private:
  59.     void readConfig(char *filename);
  60.     void saveConfig(char *filename);
  61.     void getConfigFileName(char *name,int namesize);
  62. };
  63. #endif
  64.  
  65.