21 #ifndef VOICECALL_ENG_H 22 #define VOICECALL_ENG_H 25 #include <QAbstractTableModel> 27 #include "../datamodel/model.h" 28 #include "../datamodel/voicecall.h" 29 #include "../call/audiodecoder.h" 97 const QByteArray& aPayload,
98 const Hash& aSendingNode) ;
130 const Hash& aSendingNode) ;
142 virtual void closeCall(quint32 aCallId) ;
163 virtual int rowCount(
const QModelIndex & parent = QModelIndex())
const ;
168 virtual int columnCount(
const QModelIndex & parent = QModelIndex())
const ;
173 virtual QVariant
data(
const QModelIndex & index,
174 int role = Qt::DisplayRole)
const ;
180 Qt::Orientation orientation,
181 int role = Qt::DisplayRole )
const ;
189 const Hash aHashOfAttemptedNode );
200 const QByteArray& aEncodedVoice ) ;
220 void error(QTcpSocket::SocketError socketError);
263 const Hash& aSendingNode)
const ;
class for de-compressing audio received from network
Definition: audiodecoder.h:32
opposite of audiosink.
Definition: audiosource.h:41
AudioSource * iAudioSource
Definition: voicecallengine.h:332
virtual int rowCount(const QModelIndex &parent=QModelIndex()) const
virtual QVariant headerData(int section, Qt::Orientation orientation, int role=Qt::DisplayRole) const
Pure-virtual interface for voice call engine.
Definition: mvoicecallengine.h:33
CallState iOnGoingCallState
Definition: voicecallengine.h:303
void startProcessCallData()
void callStateChanged(quint32 aCallId, VoiceCallEngine::CallState aState)
virtual CallState callStatus(quint32 aCallId) const
void setOutputLevel(float aOutputLevel)
VoiceCallEngine(MController &aController, Model &aModel)
QString iPeerNodeAddress
Definition: voicecallengine.h:307
virtual void insertCallStatusData(const VoiceCall &aCallStatus, const Hash &aSendingNode)
QByteArray asJSon() const
QString excuseForCallCreation(const Hash &aOperator, const Hash &aNode=KNullHash) const
Class for playback of audio stream, via speaker or other audio dev.
Definition: audioplayer.h:38
Class for mixing together 0-n audio streams.
Definition: audiomixer.h:44
void addCallToArray(VoiceCallExtension &aCall)
virtual void removeObserver(MCallStatusObserver *aObserver)
virtual int columnCount(const QModelIndex &parent=QModelIndex()) const
void audioFrameEncoded(quint32 aCallId, quint32 aSeqNo, const QByteArray &aEncodedVoice)
virtual void closeCall(quint32 aCallId)
MController & iController
Definition: voicecallengine.h:315
class for compressing audio to be sent over network
Definition: audioencoder.h:34
AudioDecoder * iDecoder
Definition: voicecallengine.h:313
bool removeCallFromMixer(const VoiceCallExtension &aCall)
Carrier-class handling audio negotiation setup and data.
Definition: voicecall.h:40
void removeCallFromArray(VoiceCallExtension &aCall)
void sendCallStatusUpdateToRemote(const VoiceCall &aCall, bool aDoSign=true)
Hash is class that carries 160-bit digest.
Definition: hash.h:38
virtual void insertCallData(quint32 aCallId, quint32 aSeqNo, PayloadType aPayloadType, const QByteArray &aPayload, const Hash &aSendingNode)
ConnectionState
Definition: connection.h:47
QString iPeerOperatorHash
Definition: voicecallengine.h:305
~VoiceCallExtension()
Definition: voicecallengine.h:296
virtual void acceptCall(quint32 aCallId)
AudioMixer * iMixer
Definition: voicecallengine.h:325
bool setupNewIncomingCall(VoiceCallExtension &aCall)
virtual void installObserver(MCallStatusObserver *aObserver)
AudioEncoder * iEncoder
Definition: voicecallengine.h:331
void error(QTcpSocket::SocketError socketError)
Pure-virtual interface class for controller. This is spammed across parties needing access to applica...
Definition: mcontroller.h:43
Hash callPeerFingerPrint(const VoiceCall &aCall) const
PayloadType
Definition: mvoicecallengine.h:63
QList< VoiceCallExtension > iOnGoingCalls
Definition: voicecallengine.h:318
bool addCallToMixer(const VoiceCallExtension &aCall)
bool fromJSon(const QByteArray &aJSonBytes)
virtual QList< quint32 > onGoingCalls() const
Model & iModel
Definition: voicecallengine.h:316
M of the MVC pattern. Handles permanent storage.
Definition: model.h:48
Definition: mvoicecallengine.h:52
CallState
Definition: mvoicecallengine.h:38
void setInputLevel(float aInputLevel)
bool setupNewOutgoingCall(VoiceCallExtension &aCall)
void inputLevel(float aInputLevel)
VoiceCallExtension(const VoiceCall &aInitialData)
Definition: voicecallengine.h:292
void nodeConnectionAttemptStatus(Connection::ConnectionState aStatus, const Hash aHashOfAttemptedNode)
virtual QVariant data(const QModelIndex &index, int role=Qt::DisplayRole) const
QList< QPair< VoiceCall, Hash > > iCallDataPendingProcessing
Definition: voicecallengine.h:334
AudioPlayer * iAudioPlayer
Definition: voicecallengine.h:333
bool checkForNodeValidity(const VoiceCall &aCallStatus, const Hash &aSendingNode) const
QList< MCallStatusObserver * > iCallObservers
Definition: voicecallengine.h:317
bool setupAudioOutput(VoiceCallExtension &aCall)
QString callStatusString(const VoiceCallExtension &aCall) const
void outputLevel(float aOutputLevel)
Definition: voicecallengine.h:289
void sendCallStatusUpdates(quint32 aCallId, CallState aState)
Network-related logic for handling voice channel between nodes.
Definition: voicecallengine.h:53
bool setupLocalAudioCapture(VoiceCallExtension &aCall)