goldendict-ng/src/audiooutput.hh

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

28 lines
508 B
C++
Raw Normal View History

#ifndef AUDIOOUTPUT_H
#define AUDIOOUTPUT_H
#include <QObject>
#include <QScopedPointer>
class AudioOutputPrivate;
class AudioOutput: public QObject
{
public:
AudioOutput( QObject * parent = nullptr );
~AudioOutput();
bool play( const uint8_t * data, qint64 len );
void setAudioFormat( int sampleRate, int channels );
void stop();
protected:
QScopedPointer< AudioOutputPrivate > d_ptr;
private:
Q_DISABLE_COPY( AudioOutput )
Q_DECLARE_PRIVATE( AudioOutput )
};
#endif // AUDIOOUTPUT_H