RetroShare/plugins/VOIP/gui/AudioPopupChatDialog.h
thunder2 232af8e71e Changed SoundManger to allow the plugins to play sounds.
Added example to VOIP (commented out).

git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@5709 b45a01b8-16f6-495d-af2f-9b41ad6348cc
2012-10-21 21:38:55 +00:00

44 lines
928 B
C++

#include <QObject>
#include <QGraphicsEffect>
#include <gui/SpeexProcessor.h>
#include <gui/chat/PopupChatDialog.h>
#include <gui/audiodevicehelper.h>
class QPushButton;
#define VOIP_SOUND_INCOMING_CALL "VOIP_incoming_call"
class AudioPopupChatDialog: public PopupChatDialog
{
Q_OBJECT
public:
AudioPopupChatDialog(QWidget *parent = NULL);
virtual ~AudioPopupChatDialog()
{
if(inputDevice != NULL)
inputDevice->stop() ;
}
void addAudioData(const QString name, QByteArray* array) ;
private slots:
void toggleAudioListen();
void toggleAudioMuteCapture();
public slots:
void sendAudioData();
protected:
QAudioInput* inputDevice;
QAudioOutput* outputDevice;
QtSpeex::SpeexInputProcessor* inputProcessor;
QtSpeex::SpeexOutputProcessor* outputProcessor;
virtual void updateStatus(int status) ;
QPushButton *audioListenToggleButton ;
QPushButton *audioMuteCaptureToggleButton ;
};