Main class to creates a SERVER (to listen) or a CLIENT (to connect to a listening server) to send audio streams in the network.
More...
|
| | JackTrip (jacktripModeT JacktripMode=CLIENT, dataProtocolT DataProtocolType=UDP, int NumChans=gDefaultNumInChannels, int BufferQueueLength=gDefaultQueueLength, unsigned int redundancy=gDefaultRedundancy, AudioInterface::audioBitResolutionT AudioBitResolution=AudioInterface::BIT16, DataProtocol::packetHeaderTypeT PacketHeaderType=DataProtocol::DEFAULT, underrunModeT UnderRunMode=WAVETABLE, int receiver_bind_port=gDefaultPort, int sender_bind_port=gDefaultPort, int receiver_peer_port=gDefaultPort, int sender_peer_port=gDefaultPort) |
| | The class Constructor with Default Parameters. More...
|
| |
| virtual | ~JackTrip () |
| | The class destructor. More...
|
| |
| virtual void | run () |
| | Starting point for the thread. More...
|
| |
| virtual void | setPeerAddress (const char *PeerHostOrIP) |
| | Set the Peer Address for jacktripModeT::CLIENT mode only. More...
|
| |
| virtual void | appendProcessPlugin (ProcessPlugin *plugin) |
| | Append a process plugin. Processes will be appended in order. More...
|
| |
| virtual void | startProcess () throw (std::invalid_argument) |
| | Start the processing threads. More...
|
| |
| virtual void | stop () |
| | Stop the processing threads. More...
|
| |
| virtual void | waitThreads () |
| | Wait for all the threads to finish. This functions is used when JackTrip is run as a thread. More...
|
| |
| virtual void | checkIfPortIsBinded (int port) |
| | Check if UDP port is already binded. More...
|
| |
| void | printTextTest () |
| |
| void | printTextTest2 () |
| |
| virtual void | setupAudio () |
| | Set the AudioInteface object. More...
|
| |
| void | closeAudio () |
| | Close the JackAudioInteface and disconnects it from JACK. More...
|
| |
| virtual void | setupDataProtocol () |
| | Set the DataProtocol objects. More...
|
| |
| void | setupRingBuffers () |
| | Set the RingBuffer objects. More...
|
| |
| void | clientStart () throw (std::invalid_argument) |
| | Starts for the CLIENT mode. More...
|
| |
| int | serverStart (bool timeout=false, int udpTimeout=gTimeOutMultiThreadedServer) throw (std::invalid_argument, std::runtime_error) |
| | Starts for the SERVER mode. More...
|
| |
| virtual int | clientPingToServerStart () throw (std::invalid_argument) |
| | Stats for the Client to Ping Server. More...
|
| |
|
| virtual void | setJackTripMode (jacktripModeT JacktripMode) |
| | Sets (override) JackTrip Mode after construction. More...
|
| |
| virtual void | setDataProtocoType (dataProtocolT DataProtocolType) |
| | Sets (override) DataProtocol Type after construction. More...
|
| |
| virtual void | setPacketHeaderType (DataProtocol::packetHeaderTypeT PacketHeaderType) |
| | Sets the Packet header type. More...
|
| |
| virtual void | setBufferQueueLength (int BufferQueueLength) |
| | Sets (override) Buffer Queue Length Mode after construction. More...
|
| |
| virtual void | setAudioBitResolution (AudioInterface::audioBitResolutionT AudioBitResolution) |
| | Sets (override) Audio Bit Resolution after construction. More...
|
| |
| virtual void | setUnderRunMode (underrunModeT UnderRunMode) |
| | Sets (override) Underrun Mode. More...
|
| |
| virtual void | setAllPorts (int port) |
| | Sets port numbers for the local and peer machine. Receive port is port More...
|
| |
| virtual void | setBindPorts (int port) |
| | Sets port numbers to bind in RECEIVER and SENDER sockets. More...
|
| |
| virtual void | setPeerPorts (int port) |
| | Sets port numbers for the peer (remote) machine. More...
|
| |
| virtual void | setClientName (const char *ClientName) |
| | Set Client Name to something different that the default (JackTrip) More...
|
| |
| virtual void | setNumChannels (int num_chans) |
| | Set the number of audio channels. More...
|
| |
| virtual int | getReceiverBindPort () const |
| |
| virtual int | getSenderPeerPort () const |
| |
| virtual int | getSenderBindPort () const |
| |
| virtual int | getReceiverPeerPort () const |
| |
| virtual DataProtocol * | getDataProtocolSender () const |
| |
| virtual DataProtocol * | getDataProtocolReceiver () const |
| |
| virtual void | setDataProtocolSender (DataProtocol *const DataProtocolSender) |
| |
| virtual void | setDataProtocolReceiver (DataProtocol *const DataProtocolReceiver) |
| |
| virtual RingBuffer * | getSendRingBuffer () const |
| |
| virtual RingBuffer * | getReceiveRingBuffer () const |
| |
| virtual void | setSendRingBuffer (RingBuffer *const SendRingBuffer) |
| |
| virtual void | setReceiveRingBuffer (RingBuffer *const ReceiveRingBuffer) |
| |
| virtual void | setPacketHeader (PacketHeader *const PacketHeader) |
| |
| virtual int | getRingBuffersSlotSize () |
| |
| virtual void | setAudiointerfaceMode (JackTrip::audiointerfaceModeT audiointerface_mode) |
| |
| virtual void | setAudioInterface (AudioInterface *const AudioInterface) |
| |
| void | setSampleRate (uint32_t sample_rate) |
| |
| void | setAudioBufferSizeInSamples (uint32_t buf_size) |
| |
| JackTrip::connectionModeT | getConnectionMode () const |
| |
| void | setConnectionMode (JackTrip::connectionModeT connection_mode) |
| |
| JackTrip::jacktripModeT | getJackTripMode () const |
| |
| QString | getPeerAddress () const |
| |
| bool | receivedConnectionFromPeer () |
| |
| bool | tcpConnectionError () |
| |
|
| virtual void | createHeader (const DataProtocol::packetHeaderTypeT headertype) |
| |
| void | putHeaderInPacket (int8_t *full_packet, int8_t *audio_packet) |
| |
| virtual int | getPacketSizeInBytes () |
| |
| void | parseAudioPacket (int8_t *full_packet, int8_t *audio_packet) |
| |
| virtual void | sendNetworkPacket (const int8_t *ptrToSlot) |
| |
| virtual void | receiveNetworkPacket (int8_t *ptrToReadSlot) |
| |
| virtual void | readAudioBuffer (int8_t *ptrToReadSlot) |
| |
| virtual void | writeAudioBuffer (const int8_t *ptrToSlot) |
| |
| uint32_t | getBufferSizeInSamples () const |
| |
| AudioInterface::samplingRateT | getSampleRateType () const |
| |
| int | getSampleRate () const |
| |
| uint8_t | getAudioBitResolution () const |
| |
| unsigned int | getNumInputChannels () const |
| |
| unsigned int | getNumOutputChannels () const |
| |
| unsigned int | getNumChannels () const |
| |
| virtual void | checkPeerSettings (int8_t *full_packet) |
| |
| void | increaseSequenceNumber () |
| |
| int | getSequenceNumber () const |
| |
| uint64_t | getPeerTimeStamp (int8_t *full_packet) const |
| |
| uint16_t | getPeerSequenceNumber (int8_t *full_packet) const |
| |
| uint16_t | getPeerBufferSize (int8_t *full_packet) const |
| |
| uint8_t | getPeerSamplingRate (int8_t *full_packet) const |
| |
| uint8_t | getPeerBitResolution (int8_t *full_packet) const |
| |
| uint8_t | getPeerNumChannels (int8_t *full_packet) const |
| |
| uint8_t | getPeerConnectionMode (int8_t *full_packet) const |
| |
| size_t | getSizeInBytesPerChannel () const |
| |
| int | getHeaderSizeInBytes () const |
| |
| virtual int | getTotalAudioPacketSizeInBytes () const |
| |
Main class to creates a SERVER (to listen) or a CLIENT (to connect to a listening server) to send audio streams in the network.
All audio and network settings can be set in this class. This class also acts as a Mediator between all the other class. Classes that uses JackTrip methods need to register with it.