JackServer.h

00001 /*
00002 Copyright (C) 2001 Paul Davis 
00003 Copyright (C) 2004-2006 Grame
00004 
00005 This program is free software; you can redistribute it and/or modify
00006 it under the terms of the GNU General Public License as published by
00007 the Free Software Foundation; either version 2 of the License, or
00008 (at your option) any later version.
00009 
00010 This program is distributed in the hope that it will be useful,
00011 but WITHOUT ANY WARRANTY; without even the implied warranty of
00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013 GNU General Public License for more details.
00014 
00015 You should have received a copy of the GNU General Public License
00016 along with this program; if not, write to the Free Software
00017 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00018 
00019 */
00020 
00021 #ifndef __JackServer__
00022 #define __JackServer__
00023 
00024 #include "JackExports.h"
00025 #include "driver_interface.h"
00026 #include "JackDriverLoader.h"
00027 #include "jslist.h"
00028 
00029 namespace Jack
00030 {
00031 
00032 class JackGraphManager;
00033 class JackConnectionManager;
00034 class JackDriverClientInterface;
00035 class JackServerChannelInterface;
00036 class JackSyncInterface;
00037 struct JackEngineControl;
00038 class JackEngine;
00039 
00044 class EXPORT JackServer
00045 {
00046 
00047     private:
00048 
00049         jack_driver_info_t* fDriverInfo;
00050         JackDriverClientInterface* fAudioDriver;
00051         JackDriverClientInterface* fFreewheelDriver;
00052         JackDriverClientInterface* fLoopbackDriver;
00053         JackEngine* fEngine;
00054         JackEngineControl* fEngineControl;
00055         JackGraphManager* fGraphManager;
00056         JackServerChannelInterface* fChannel;
00057         JackConnectionManager* fState;
00058         JackSynchro* fSynchroTable[CLIENT_NUM];        
00059         bool fFreewheel;
00060         long fLoopback;
00061 
00062     public:
00063 
00064         JackServer(bool sync, bool temporary, long timeout, bool rt, long priority, long loopback, bool verbose);
00065         virtual ~JackServer();
00066 
00067         int Open(jack_driver_desc_t* driver_desc, JSList* driver_params);
00068                 int Close();
00069 
00070         int Start();
00071         int Stop();
00072 
00073         int SetBufferSize(jack_nframes_t buffer_size);
00074         int SetFreewheel(bool onoff);
00075         void Notify(int refnum, int notify, int value);
00076                 
00077                 int InternalClientLoad(const char* client_name, const char* so_name, const char* objet_data, int options, int* int_ref, int* status);
00078         
00079         JackEngine* GetEngine();
00080         JackEngineControl* GetEngineControl();
00081         JackSynchro** GetSynchroTable();
00082         JackGraphManager* GetGraphManager();
00083 
00084         static JackServer* fInstance; // Unique instance
00085 };
00086 
00087 } // end of namespace
00088 
00089 
00090 #endif

Generated on Mon Oct 15 17:11:14 2007 for Jackdmp by  doxygen 1.5.1