A DTMF sequence editor and player for HAM radio equipment command & control.

Dependencies:   mbed ExtTextLCD

Committer:
osmeest
Date:
Mon Mar 07 22:51:19 2011 +0000
Revision:
0:1324e7d9d471

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
osmeest 0:1324e7d9d471 1 #ifndef BUFFERED_WAVE_H_
osmeest 0:1324e7d9d471 2 #define BUFFERED_WAVE_H_
osmeest 0:1324e7d9d471 3
osmeest 0:1324e7d9d471 4 #include "snd_wave_generator/Wave.h"
osmeest 0:1324e7d9d471 5 #include "snd_wave_generator/WaveBuffer.h"
osmeest 0:1324e7d9d471 6
osmeest 0:1324e7d9d471 7 namespace snd_wave_generator {
osmeest 0:1324e7d9d471 8
osmeest 0:1324e7d9d471 9 /**
osmeest 0:1324e7d9d471 10 * @brief A base class for Waves which pre-computes their values in a buffer during preparation and play from that buffer.
osmeest 0:1324e7d9d471 11 */
osmeest 0:1324e7d9d471 12 class BufferedWave : public Wave {
osmeest 0:1324e7d9d471 13 public:
osmeest 0:1324e7d9d471 14 BufferedWave() : buffer() { }
osmeest 0:1324e7d9d471 15 virtual float read(std::size_t pos) const { return this->buffer.read(pos); }
osmeest 0:1324e7d9d471 16
osmeest 0:1324e7d9d471 17 protected:
osmeest 0:1324e7d9d471 18 WaveBuffer buffer;
osmeest 0:1324e7d9d471 19 };
osmeest 0:1324e7d9d471 20
osmeest 0:1324e7d9d471 21 } // snd_wave_generator
osmeest 0:1324e7d9d471 22
osmeest 0:1324e7d9d471 23 #endif // BUFFERED_WAVE_H_