diff options
author | Sakari Bergen <sakari.bergen@beatwaves.net> | 2010-03-15 19:11:48 +0000 |
---|---|---|
committer | Sakari Bergen <sakari.bergen@beatwaves.net> | 2010-03-15 19:11:48 +0000 |
commit | 830911f6f9451d83a58043b3f9084d3caa164b7b (patch) | |
tree | f4ca4e3d86b51d66e7cecfb6b370cc4eb553e2d7 /libs/audiographer/audiographer/sndfile/tmp_file.h | |
parent | 44f4b84551d36ef4103d09452768f5ba53e0002c (diff) |
Fix export, which has been broken since the boost::signals2 changes. Also update Audiographer, bacause of its incomplete sndfile handling. Audiographer is equal to revision 74
git-svn-id: svn://localhost/ardour2/branches/3.0@6760 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/audiographer/audiographer/sndfile/tmp_file.h')
-rw-r--r-- | libs/audiographer/audiographer/sndfile/tmp_file.h | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/libs/audiographer/audiographer/sndfile/tmp_file.h b/libs/audiographer/audiographer/sndfile/tmp_file.h new file mode 100644 index 0000000000..e312007247 --- /dev/null +++ b/libs/audiographer/audiographer/sndfile/tmp_file.h @@ -0,0 +1,27 @@ +#ifndef AUDIOGRAPHER_TMP_FILE_H +#define AUDIOGRAPHER_TMP_FILE_H + +#include "sndfile_writer.h" +#include "sndfile_reader.h" + +namespace AudioGrapher +{ + +/// A temporary file deleted after this class is destructed +template<typename T = DefaultSampleType> +class TmpFile : public SndfileWriter<T>, public SndfileReader<T> +{ + public: + + TmpFile (int format, ChannelCount channels, nframes_t samplerate) + : SndfileHandle (fileno (tmpfile()), true, SndfileBase::ReadWrite, format, channels, samplerate) + {} + + TmpFile (TmpFile const & other) : SndfileHandle (other) {} + using SndfileHandle::operator=; + +}; + +} // namespace + +#endif // AUDIOGRAPHER_TMP_FILE_H
\ No newline at end of file |