[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |
The user then starts a JACK client program. It opens a connection to the server and provides it with all information that the server will need to run the application again. This information includes: the current directory that the user was in when they ran the program, the command line that started the application and the class of the client (a character string that the client application provides the initialisation routine that will never change over all initialisations.)
With this information is included a set
of flags that describe the client to the server. This particular
client saves data to files and wants the server to tell it where to
save files when the project is saved, so it has the
CCA_Config_File
flag set.
The client library starts two threads for communication with the server, one for sending data and the other for recieving. It also sends, along with the client supplied data, a number of parameters that were extracted from the client's command line options before it checked them. This optionally includes the name of the project that the client should initially be associated with and a 128-bit, world-unique identifier for this particular client instance (the LADCCCA ID.)
Server-side, the server wakes up to the fact that a new connection has arrived and immediately adds it to a list of open connections and then goes back to waiting. When the client sends the requisite information, the server looks at it and decides what to do with the client. This client has not requested a specific project to which it should be connected. However, there are no existing projects so the server creates a new project with the name `project-1' in the directory `/home/user/audio-projects/project-1' (assuming the user didn't specify a different default directory when running configure.) It also generates a new LADCCA ID for the client. It then adds the client to the new project and goes back to listening.
The client then connects up to the JACK server and, after having done this,
sends a CCA_Jack_Client_Name
event to the server with the name that
it registered to JACK with as the string. This notifies the server that it
is a JACK client and needs its JACK port connections saved and restored.
The server will now pay attention to any activity regarding the client
(ie, port creation and destruction and port connection and disconnection.)
[ < ] | [ > ] | [ << ] | [ Up ] | [ >> ] | [Top] | [Contents] | [Index] | [ ? ] |