diff options
| author | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2008-11-20 11:10:02 +0000 |
|---|---|---|
| committer | trialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38> | 2008-11-20 11:10:02 +0000 |
| commit | a030a982fc4194e81b21a36c1fb0a505f8e2e28b (patch) | |
| tree | fdbcaa5f5bc3901078b9dcd9d20782c30c3c6899 /src/plugins/Output/alsa/outputalsa.h | |
| parent | a008a77ed5aecdc1f1f000cff1cb7a5e03b18e3c (diff) | |
| download | qmmp-a030a982fc4194e81b21a36c1fb0a505f8e2e28b.tar.gz qmmp-a030a982fc4194e81b21a36c1fb0a505f8e2e28b.tar.bz2 qmmp-a030a982fc4194e81b21a36c1fb0a505f8e2e28b.zip | |
output api changes
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@622 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src/plugins/Output/alsa/outputalsa.h')
| -rw-r--r-- | src/plugins/Output/alsa/outputalsa.h | 36 |
1 files changed, 10 insertions, 26 deletions
diff --git a/src/plugins/Output/alsa/outputalsa.h b/src/plugins/Output/alsa/outputalsa.h index 9bd6e0e4a..3ddf4278c 100644 --- a/src/plugins/Output/alsa/outputalsa.h +++ b/src/plugins/Output/alsa/outputalsa.h @@ -42,46 +42,30 @@ public: ~OutputALSA(); bool initialize(); - bool isInitialized() const - { - return m_inited; - } - void uninitialize(); void configure(quint32, int, int); - void stop(); - void pause(); - qint64 written(); qint64 latency(); - void seek(qint64); private: - // thread run function - void run(); + //output api + qint64 writeAudio(unsigned char *data, qint64 maxSize); + void flush(); // helper functions void reset(); - void status(); long alsa_write(unsigned char *data, long size); + void uninitialize(); - bool m_inited, m_pause, m_play, m_userStop; - qint64 m_totalWritten, m_currentSeconds, m_bps; - int m_rate, m_channels, m_precision; - quint32 m_frequency; + bool m_inited; + bool m_use_mmap; //alsa snd_pcm_t *pcm_handle; char *pcm_name; - //alsa snd_pcm_uframes_t m_chunk_size; size_t m_bits_per_frame; - - //alsa mixer - /*int setupMixer(QString card, QString device); - void parseMixerName(char *str, char **name, int *index); - int getMixer(snd_mixer_t **mixer, QString card); - snd_mixer_elem_t* getMixerElem(snd_mixer_t *mixer, char *name, int index); - snd_mixer_t *mixer; - snd_mixer_elem_t *pcm_element;*/ - bool m_use_mmap; + //prebuffer + uchar *m_prebuf; + qint64 m_prebuf_size; + qint64 m_prebuf_fill; }; class VolumeControlALSA : public VolumeControl |
