00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef __JackClientControl__
00022 #define __JackClientControl__
00023
00024 #include "JackShmMem.h"
00025 #include "JackPort.h"
00026 #include "JackSynchro.h"
00027 #include "JackNotification.h"
00028 #include "transport_types.h"
00029
00030 namespace Jack
00031 {
00032
00037 struct JackClientControl : public JackShmMem
00038 {
00039 char fName[JACK_CLIENT_NAME_SIZE + 1];
00040 bool fCallback[kMaxNotification];
00041 volatile jack_transport_state_t fTransportState;
00042 int fRefNum;
00043 bool fActive;
00044
00045 JackClientControl(const char* name, int refnum)
00046 {
00047 Init(name, refnum);
00048 }
00049
00050 JackClientControl(const char* name)
00051 {
00052 Init(name, -1);
00053 }
00054
00055 JackClientControl()
00056 {
00057 Init("", -1);
00058 }
00059
00060 void Init(const char* name, int refnum)
00061 {
00062 strcpy(fName, name);
00063 for (int i = 0; i < kMaxNotification; i++)
00064 fCallback[i] = false;
00065
00066 fCallback[kAddClient] = true;
00067 fCallback[kRemoveClient] = true;
00068 fCallback[kActivateClient] = true;
00069
00070 fCallback[kStartFreewheelCallback] = true;
00071 fCallback[kStopFreewheelCallback] = true;
00072 fRefNum = refnum;
00073 fTransportState = JackTransportStopped;
00074 fActive = false;
00075 }
00076
00077 };
00078
00079 }
00080
00081
00082 #endif